Currently we can't run e2e tests in headless mode. This is due to limitations in headless Chromium that makes it impossible to render certain models in PlayCanvas. Headless also seems less performant than headful when using WebGL.
Please refrain from interacting with your computer while running the e2e tests as it may affect the test result.
E2E tests will automatically run on GitLab CI. If they fail, the snapshot diff output will be saved as an artifact and can be viewed/downloaded via the GitLab CI web GUI.
If the tests fail due to an expected or intentional diff, the baseline snapshot should be updated by manually triggering
job test_e2e_update
in the GitLab CI web GUI. This will run the tests again with the --updateSnapshot
argument and
automatically commit the updated snapshots to the same branch.
npm run test:e2e
Runs all e2e tests once.
npm run test:e2e-watch
Launches the e2e test runner in watch mode.
npm run test:e2e-update
Runs e2e tests with the --updateSnapshot
argument, automatically updating the snapshot baseline from the test result.