diff --git a/.circleci/README.md b/.circleci/README.md index 5544fe06a..b340d82ce 100644 --- a/.circleci/README.md +++ b/.circleci/README.md @@ -189,13 +189,13 @@ Tests run in this sequence (see `commands.run_tests` around [config.yml:153-170] ### Test Structure -**End-to-end tests** ([_tests/e2e-test.mjs](../_tests/e2e-test.mjs)): +**End-to-end tests** ([tests/e2e-test.mjs](../tests/e2e-test.mjs)): 1. Creates new publication via `quire new` 2. Builds HTML via `quire build` 3. Generates PDF via `quire pdf` 4. Generates EPUB via `quire epub` -**Browser tests** ([_tests/publication.spec.js](../_tests/publication.spec.js)): +**Browser tests** ([tests/publication.spec.js](../tests/publication.spec.js)): - Run twice per platform: once at root path `/` and once with pathname `/quire-test-project/` - Validate page titles, image URLs, IIIF canvas-panel dimensions - Use sitemap for page discovery @@ -342,7 +342,7 @@ circleci config process .circleci/config.yml # Expand orbs/anchors ```bash npx playwright test --headed # See browser npx playwright test --debug # Step through -npx playwright test _tests/publication.spec.js # Single file +npx playwright test tests/publication.spec.js # Single file ``` **Failed test locally:** diff --git a/.circleci/build.yml b/.circleci/build.yml index 7484415d4..d2c0b0a8f 100644 --- a/.circleci/build.yml +++ b/.circleci/build.yml @@ -188,7 +188,7 @@ commands: - reports - test-publication-pathname/_site - test-publication/_site - - _tests + - tests - store_test_results: path: reports diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md index 42d3c309b..4ae31d868 100644 --- a/DEVELOPMENT.md +++ b/DEVELOPMENT.md @@ -151,7 +151,7 @@ mise pw:debug # Interactive debug mode **Test specific file:** ```bash -npx playwright test _tests/publication.spec.js +npx playwright test tests/publication.spec.js ``` **View test report:** diff --git a/package.json b/package.json index 48a713a0e..1d00e505a 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "environmentVariables": {}, "failFast": true, "files": [ - "./_tests/*-test.mjs" + "./tests/*-test.mjs" ], "workerThreads": false }, diff --git a/playwright.config.js b/playwright.config.js index 90ba2a04f..7717818f7 100644 --- a/playwright.config.js +++ b/playwright.config.js @@ -8,7 +8,7 @@ const pathnameTesting = !!process.env.QUIRE_TEST_PUB_PATHNAME */ export default defineConfig({ expect: { toHaveScreenshot: { maxDiffPixels: 100 } }, - testDir: './_tests', + testDir: './tests', /* Run tests in files in parallel */ fullyParallel: true, /* Fail the build on CI if you accidentally left test.only in the source code. */ diff --git a/_tests/README.md b/tests/README.md similarity index 100% rename from _tests/README.md rename to tests/README.md diff --git a/_tests/e2e-test.mjs b/tests/e2e-test.mjs similarity index 100% rename from _tests/e2e-test.mjs rename to tests/e2e-test.mjs diff --git a/_tests/helpers/publication-setup.js b/tests/helpers/publication-setup.js similarity index 100% rename from _tests/helpers/publication-setup.js rename to tests/helpers/publication-setup.js diff --git a/_tests/publication.spec.js b/tests/publication.spec.js similarity index 100% rename from _tests/publication.spec.js rename to tests/publication.spec.js