Selenium WebDriver 4

Generate an HTML test report

Hard120 pts~45 min
  • Reporting
  • Test hooks
Practice app · Acme Ops

A sign-in page with field validation and an authenticated dashboard.

Test URL
/lab/selenium-generate-an-html-test-report

Your starter code already declares TEST_URL — never hardcode a host.

Objective

Record each step of the sign-in test and write an HTML report with its status and duration.

Your task

  1. 1Record steps (open, sign in, verify dashboard) with name, status and duration.
  2. 2After the test, write reports/report.html containing a table of the steps — or use Extent Reports, pytest-html or mochawesome.
  3. 3Sign in with qa@target.dev / Test@123 (#username, #password, #login-button).
  4. 4Assert the welcome message, then assert the report file exists and is not empty.

Acceptance criteria

  • An HTML report is written
  • The dashboard is shown
  • At least 2 assertions pass

Fixtures

username
qa@target.dev
password
Test@123

Selenium WebDriver 4 · Selenium · Grid, parallel & CI