Files
Frontend_automation/.env.test.example

35 lines
1.3 KiB
Plaintext
Raw Normal View History

Extract PassDashboard Playwright e2e suite into standalone repo Copies the Playwright end-to-end suite out of the PassDashboard app repo so it can be run and deployed independently. Nothing was removed from the app repo - this is a copy. Carried over verbatim: tests/ (10 spec files, 4 helper modules, README) plus playwright.config.ts and .env.test.example. The suite drives the deployed app over HTTP and imports nothing from src/, which is what makes it standalone. New for this repo: - package.json with only the deps the suite actually uses (@playwright/test, allure-playwright, xlsx, typescript, @types/node) and the e2e scripts. - tsconfig.json covering tests/ - the app repo's tsconfig.app.json only included src/, so these files were never typechecked before. - .gitea/workflows/e2e-tests.yml for Gitea Actions. The app repo derived ENV from github.ref_name; that doesn't apply here since this repo has no per-environment branches, so the target is an explicit workflow_dispatch input and scheduled/push runs default to develop. Reports are uploaded as artifacts rather than deleted. - .gitignore and README covering local setup and the required CI secrets. The Jest unit tests under src/__tests__/ were deliberately left in the app repo: they import application source directly (AuthContext, ProtectedRoute, cryptoUtils, api) and cannot run without it. Verified: npx tsc --noEmit is clean and playwright collects all 43 tests across all 10 spec files. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-03 15:50:50 +03:00
# Local e2e test credentials - copy this file to .env.test.local and fill in
# real values. .env.test.local is git-ignored (matches the `*.local` pattern
# in .gitignore) so real credentials never get committed.
#
# In CI, these same variable names are set directly from GitHub Secrets
# (see CI-CD-SETUP.md) - this file is only read for local runs.
# Which environment to run against: develop | staging | main
# (also accepts dev | staging | production - same thing)
ENV=develop
# Dev environment (used when ENV=develop/dev) - its own deployment, separate
# from staging. Falls back to TEST_USERNAME/TEST_PASSWORD below if unset.
DEV_URL=
DEV_USERNAME=
DEV_PASSWORD=
# Older shared dev credentials - kept as a fallback for DEV_USERNAME/PASSWORD
# above and for staging (see below), matching how CI already provisions it.
TEST_USERNAME=
TEST_PASSWORD=
# Staging credentials (optional - falls back to TEST_USERNAME/TEST_PASSWORD
# above if not set, matching how CI has always provisioned staging)
STAGING_TEST_USERNAME=
STAGING_TEST_PASSWORD=
# Production credentials (required when ENV=main/production - kept separate
# on purpose so dev credentials can never accidentally run against prod)
PROD_TEST_USERNAME=
PROD_TEST_PASSWORD=
# Optional: override the environment's default base URL entirely
# BASE_URL=