src/ui/cypress/README.md
These tests use [Cypress][https://docs.cypress.io] to run integration tests in a browser.
To run them, you need two things:
dev.withpixie.dev which comes from the self-host instructions.default-sessionSOME_NUMBER cookie. That is what you'll use to set CYPRESS_GOOGLE_SESSION_COOKIE.
The name of that cookie will set CYPRESS_GOOGLE_SESSION_COOKIE_KEY.Then, run this command to access Cypress' UI:
CYPRESS_BASE_URL='https://dev.withpixie.dev' CYPRESS_GOOGLE_SESSION_COOKIE_KEY='default-sessionSOME_NUMBER' CYPRESS_GOOGLE_SESSION_COOKIE='paste-your-session-cookie-value-here' yarn cypress open
You can use ... yarn cypress:run:chrome (or ... yarn cypress:run:firefox) instead if you want to run the tests immediately and headlessly.
If you don't want to set these environment variables every time, you can override everything except the base URL in cypress.env.json (copy from cypress.template.env.json):
{
"GOOGLE_SESSION_COOKIE_KEY": "default-sessionSOME_NUMBER",
"GOOGLE_SESSION_COOKIE": "paste it here"
}