Skip to content

Add end2end tests#470

Merged
camillobruni merged 8 commits intoWebKit:mainfrom
camillobruni:2025-01-07_test_all
Jan 22, 2025
Merged

Add end2end tests#470
camillobruni merged 8 commits intoWebKit:mainfrom
camillobruni:2025-01-07_test_all

Conversation

@camillobruni
Copy link
Contributor

@camillobruni camillobruni commented Jan 7, 2025

  • Move unitests to run-unittests.mjs
  • Move common test driver and server setup to separate helper.mjs module
  • Add SpeedometerReady and SpeedometerDone events for easier testing
  • Add simple end2end tests

Copy link
Contributor

@flashdesignory flashdesignory left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bgrins bgrins requested a review from julienw January 7, 2025 18:52
Copy link
Contributor

@julienw julienw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, this looks good to me
I only have a few nits before landing :) see comments below
thanks for the new tests!

@camillobruni
Copy link
Contributor Author

Updated a few more things

  • updated required selenium version to 4.27 to fix local runs
  • installed better error handlers to catch runner errors in the end2end tests
  • moved benchmark-runner-tests.mjs to tests/unittests

@julienw
Copy link
Contributor

julienw commented Jan 15, 2025

Thanks, I like the fact we call a function better (didn't want to highlight it before :-) )

BTW I wonder if there's a way to run the tests headless too. How does it work on CI, is there a X server or something?

@camillobruni
Copy link
Contributor Author

headless would mostly depend on how the browser is set up.
I know how to run chrome headless e.g. it basically only needs the --headless command line flag, I think firefox has the same flag, no? (We can add that by default or make it customizable in an additional PR?)

Given that we currently only run on macOs it wont matter for the official testing (there is no real headless on macOS I think).

@camillobruni camillobruni merged commit 0c3f0fb into WebKit:main Jan 22, 2025
4 checks passed
@camillobruni camillobruni deleted the 2025-01-07_test_all branch January 22, 2025 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants