From 2ae8127476b01065c4fe05f871699397f4543ebc Mon Sep 17 00:00:00 2001 From: openhands Date: Fri, 23 Oct 2026 20:13:04 +0200 Subject: [PATCH] Add Testing and Quality Assurance section to README --- README.md | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 18150e00..005249be 100644 --- a/README.md +++ b/README.md @@ -83,24 +83,29 @@ The query builder and helper functions (`queryRows`, `execResult`, `affectedRows ### 3. Configure Environment +Copy the example environment file and edit it with your specific settings: + ```bash cp .env.example .env ``` -Edit `.env` with at minimum: +Edit `.env` to include at minimum: ```dotenv -# MySQL / MariaDB: -DATABASE_URL=mysql://user:password@127.0.0.1:3306/epicnext_cms -# Or PostgreSQL: +# Choose your database type and configure DATABASE_URL: +# For MySQL / MariaDB: +# DATABASE_URL=mysql://user:password@127.0.0.1:3306/epicnext_cms + +# For PostgreSQL: # DATABASE_URL=postgres://user:password@127.0.0.1:5432/epicnext_cms +# Ensure these are set: AUTH_SECRET= HOTEL_NAME=YourHotel APP_URL=http://localhost:3002 ``` -See `.env.example` for all optional variables (RCON, email, Valkey, OAuth, PayPal, etc.). +Refer to `.env.example` for a comprehensive list of all optional configuration variables, including RCON, email services, Valkey, OAuth providers, and PayPal integration. ### 4. Run CMS Migrations @@ -1388,6 +1393,23 @@ It is run against the public site as a `continue-on-error` CI job, so it still surfaces a real content problem without turning the pipeline red. Point either suite at any running CMS with `PLAYWRIGHT_BASE_URL`. +### Testing & Quality Assurance + +EpicNext-CMS maintains strict engineering standards enforced through automated testing pipelines: + +1. **Unit & Integration Testing (Vitest)**: + - Run tests: `pnpm test` + - Run integration tests: `pnpm test:integration` + - Covers database helpers, caching strategies, background workers, and housekeeping matrix logic. + +2. **End-to-End Testing (Playwright)**: + - Blocking deploy gate (`pnpm test:e2e`): validates critical user journeys (authentication, registration, captcha DOM contracts, security headers). + - Quality advisory suite (`pnpm test:e2e:quality`): non-blocking inspection of live content assets, page latency, and responsive layouts. + +3. **Linting & Type Safety (Biome & TypeScript)**: + - Lint check: `pnpm lint` (or `pnpm biome:check`) + - Type check: `pnpm typecheck` (strictly validates TypeScript across App Router, Server Actions, and Drizzle models). + ### Contributing 1. Ensure typecheck and tests pass: `pnpm typecheck && pnpm test`