From f70fcbbbccdb3eddbf84e0c0021799f48554d64a Mon Sep 17 00:00:00 2001 From: Chris Kenst Date: Mon, 16 Nov 2026 09:15:16 -0800 Subject: [PATCH 1/2] test: smoke-test conference archive navigation in CI --- .github/workflows/ci.yml | 12 +++++++ CONTRIBUTING.md | 16 ++++++++- ROADMAP.md | 21 +++++++++++ _config.yml | 2 ++ test/browser/.gitignore | 2 ++ test/browser/conferences.spec.js | 25 +++++++++++++ test/browser/package-lock.json | 58 +++++++++++++++++++++++++++++++ test/browser/package.json | 10 ++++++ test/browser/playwright.config.js | 19 ++++++++++ 9 files changed, 164 insertions(+), 1 deletion(-) create mode 100644 test/browser/.gitignore create mode 100644 test/browser/conferences.spec.js create mode 100644 test/browser/package-lock.json create mode 100644 test/browser/package.json create mode 100644 test/browser/playwright.config.js diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c6ba59bb..ad2eca21 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,3 +33,15 @@ jobs: - name: Validate generated site run: bundle exec htmlproofer ./_site --disable-external --no-enforce-https --allow-missing-href --ignore-urls '/^\/\//' + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '22' + + - name: Run browser smoke test + working-directory: test/browser + run: | + npm ci + npx playwright install --with-deps --only-shell chromium + npm test diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a7034e9b..02d19458 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -89,7 +89,21 @@ This is intentionally scoped to the files changed in a PR rather than a full rep - CSS/SCSS: use two-space indentation and keep related selectors grouped logically. - JavaScript: format with Prettier defaults and avoid unrelated refactors in the same change. -The main validation path remains the repo's existing checks: `ruby tools/validate_data.rb`, the valid-data tests, and the Jekyll/htmlproofer build. Additional linting tooling should only be added if it catches real issues without overhead or conflicts with the current workflow. +The main validation path uses `ruby tools/validate_data.rb`, `ruby test/validate_data_test.rb`, the Jekyll build, htmlproofer, and the browser smoke test below. Additional linting tooling should only be added if it catches real issues without overhead or conflicts with the current workflow. + +### Run the browser smoke test + +With the Ruby bundle installed and Node.js 22 available, run these commands from the repository root. + +```sh +bundle exec jekyll build +cd test/browser +npm ci +npx playwright install --only-shell chromium +npm test +``` + +Playwright serves the generated site on `127.0.0.1:4173`. Rebuild after editing site content. See [Risk coverage](ROADMAP.md#risk-coverage) for the checks and browser journeys. ## Community Guidelines diff --git a/ROADMAP.md b/ROADMAP.md index 120b92c6..f02279b4 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -29,6 +29,27 @@ The July 2026 readiness assessment found the repository ready for supervised con - [x] **Conference Data Validator**: Add a machine-checkable validator for `_data/current.yml`, `_data/past.yml`, and `_data/closed.yml` covering required fields, allowed fields, duplicate names, chronological ordering, URL tracking parameters, and `twitter` formatting. - [x] **PR Validation**: Add a pull request workflow that runs the conference data validator, Jekyll build, and htmlproofer before merge. +### Risk coverage + +| Risk | Primary check | Coverage | +| --- | --- | --- | +| Malformed YAML, missing required fields, or bad URL and handle formats | Validation | The Ruby validator checks the conference files and reports some legacy archive problems as warnings. | +| Duplicate listings or upcoming conferences in the wrong order | Validation | The validator warns on duplicate names and out-of-order parseable dates in the upcoming list. | +| Plausible but stale dates, locations, or CFP and registration statuses | Validation | Contributors verify these fields against official organizer sources during data review. | +| Liquid, Sass, or plugin failures prevent the site from being generated | Build | CI builds the site with Jekyll using the locked Ruby dependencies. | +| Published internal links, anchors, or asset paths break | Link checking | CI runs htmlproofer against the generated site. | +| Organizer, registration, or recording links stop working or point to the wrong event | Link checking | External requests are disabled in CI. Check the destination during data review and track recurring dead links under Link Integrity. | +| A valid build leaves a reader unable to find a listing, navigate the archive, find a recording, or use the newsletter form | Browser testing | CI covers archive navigation in Chromium. The other journeys below record the remaining browser coverage. | + +### Critical browser journeys + +| Journey | What the reader should be able to do | Coverage | +| --- | --- | --- | +| Find an upcoming conference | Open Upcoming, see an event name, dates, and location, and follow the event link to the organizer. | Planned | +| Browse past conferences | Start on Upcoming, click Past, and see linked entries on the archive page. | Chromium smoke test in CI | +| Find conference recordings | Click Videos, find a recent conference under its year, and follow its Watch Event Videos link. | Planned | +| Subscribe to the newsletter | Click Newsletter, find the labeled email and consent fields, and submit the form to the configured mailing-list endpoint. Intercept the submission in automation. | Planned | + ### Proposed implementation - Store one entry per released version in `_data/quality_log.yml`, with stable fields for `version`, `release_date`, `commit_sha`, Lighthouse scores, broken links, build time, and the workflow run URL. diff --git a/_config.yml b/_config.yml index 3c04c876..647d2e5e 100644 --- a/_config.yml +++ b/_config.yml @@ -14,6 +14,8 @@ plugins: # Build settings markdown: kramdown +exclude: + - test/browser defaults: - values: author: "Chris Kenst" diff --git a/test/browser/.gitignore b/test/browser/.gitignore new file mode 100644 index 00000000..d14cea40 --- /dev/null +++ b/test/browser/.gitignore @@ -0,0 +1,2 @@ +/node_modules/ +/test-results/ diff --git a/test/browser/conferences.spec.js b/test/browser/conferences.spec.js new file mode 100644 index 00000000..8f4d3546 --- /dev/null +++ b/test/browser/conferences.spec.js @@ -0,0 +1,25 @@ +const { test, expect } = require("@playwright/test"); + +test("readers can browse from Upcoming to Past conferences", async ({ + page, + baseURL, +}) => { + // Keep the journey independent of analytics, fonts, and organizer websites. + await page.route("**/*", (route) => + route.request().url().startsWith(`${baseURL}/`) + ? route.continue() + : route.abort(), + ); + + await page.goto("/"); + await expect( + page.locator(".post-list").getByRole("link").first(), + ).toBeVisible(); + + await page.getByRole("link", { name: "Past", exact: true }).click(); + await expect(page).toHaveURL(/\/past\/$/); + await expect(page).toHaveTitle("Past Software Testing Conferences"); + await expect( + page.locator(".post-list").getByRole("link").first(), + ).toBeVisible(); +}); diff --git a/test/browser/package-lock.json b/test/browser/package-lock.json new file mode 100644 index 00000000..5c76c68a --- /dev/null +++ b/test/browser/package-lock.json @@ -0,0 +1,58 @@ +{ + "name": "tcorg-browser-tests", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "tcorg-browser-tests", + "devDependencies": { + "@playwright/test": "1.65.1" + } + }, + "node_modules/@playwright/test": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/@playwright/test/-/test-1.65.1.tgz", + "integrity": "sha512-y+NCIRm2LvY4slUVWvGh1nujJ8RF/hEisIsq2mtUPgdQC4L701bq5hZGMhrpeXjACvwvO9tj5dJqhvM6TP9lbw==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "playwright": "1.65.1" + }, + "bin": { + "playwright": "cli.js" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/playwright": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/playwright/-/playwright-1.65.1.tgz", + "integrity": "sha512-vJ1FuoOrNwOKHUIVEvSt3jT1L+wjjDpwhwIstKtfvTh8XIG4FG4bIFuvNdMxi81LGfAhUgUZleVFaOLY4RIUUw==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "playwright-core": "1.65.1" + }, + "bin": { + "playwright": "cli.js" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/playwright-core": { + "version": "1.65.1", + "resolved": "https://registry.npmjs.org/playwright-core/-/playwright-core-1.65.1.tgz", + "integrity": "sha512-hqPpz7blSMPxWVdoeE1yiBSzXsKiVOd2k+kjCvmUywD2GPO2Dd9HfcWnq9NN0GHbNZDFgZ9JfBFr+X5/BLo0qw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "playwright-core": "cli.js" + }, + "engines": { + "node": ">=20" + } + } + } +} diff --git a/test/browser/package.json b/test/browser/package.json new file mode 100644 index 00000000..1f76c7c0 --- /dev/null +++ b/test/browser/package.json @@ -0,0 +1,10 @@ +{ + "name": "tcorg-browser-tests", + "private": true, + "scripts": { + "test": "playwright test" + }, + "devDependencies": { + "@playwright/test": "1.65.1" + } +} diff --git a/test/browser/playwright.config.js b/test/browser/playwright.config.js new file mode 100644 index 00000000..03c16a30 --- /dev/null +++ b/test/browser/playwright.config.js @@ -0,0 +1,19 @@ +const path = require("node:path"); +const { defineConfig } = require("@playwright/test"); + +const baseURL = "http://127.0.0.1:4173"; + +module.exports = defineConfig({ + testDir: ".", + use: { + baseURL, + browserName: "chromium", + }, + webServer: { + command: + "bundle exec ruby -run -e httpd -- --bind-address=127.0.0.1 --port=4173 _site", + cwd: path.resolve(__dirname, "../.."), + url: baseURL, + timeout: 15_000, + }, +}); From 08e14e81d6eb6e99874f2c5d95f2193d4f47dd68 Mon Sep 17 00:00:00 2001 From: Chris Kenst Date: Mon, 16 Nov 2026 09:17:47 -0800 Subject: [PATCH 2/2] fix: preserve Jekyll's default build exclusions --- {test/browser => .github/browser-tests}/.gitignore | 0 {test/browser => .github/browser-tests}/conferences.spec.js | 0 {test/browser => .github/browser-tests}/package-lock.json | 0 {test/browser => .github/browser-tests}/package.json | 0 {test/browser => .github/browser-tests}/playwright.config.js | 0 .github/workflows/ci.yml | 2 +- CONTRIBUTING.md | 2 +- _config.yml | 2 -- 8 files changed, 2 insertions(+), 4 deletions(-) rename {test/browser => .github/browser-tests}/.gitignore (100%) rename {test/browser => .github/browser-tests}/conferences.spec.js (100%) rename {test/browser => .github/browser-tests}/package-lock.json (100%) rename {test/browser => .github/browser-tests}/package.json (100%) rename {test/browser => .github/browser-tests}/playwright.config.js (100%) diff --git a/test/browser/.gitignore b/.github/browser-tests/.gitignore similarity index 100% rename from test/browser/.gitignore rename to .github/browser-tests/.gitignore diff --git a/test/browser/conferences.spec.js b/.github/browser-tests/conferences.spec.js similarity index 100% rename from test/browser/conferences.spec.js rename to .github/browser-tests/conferences.spec.js diff --git a/test/browser/package-lock.json b/.github/browser-tests/package-lock.json similarity index 100% rename from test/browser/package-lock.json rename to .github/browser-tests/package-lock.json diff --git a/test/browser/package.json b/.github/browser-tests/package.json similarity index 100% rename from test/browser/package.json rename to .github/browser-tests/package.json diff --git a/test/browser/playwright.config.js b/.github/browser-tests/playwright.config.js similarity index 100% rename from test/browser/playwright.config.js rename to .github/browser-tests/playwright.config.js diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ad2eca21..b10523c3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,7 +40,7 @@ jobs: node-version: '22' - name: Run browser smoke test - working-directory: test/browser + working-directory: .github/browser-tests run: | npm ci npx playwright install --with-deps --only-shell chromium diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 02d19458..a2620057 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -97,7 +97,7 @@ With the Ruby bundle installed and Node.js 22 available, run these commands from ```sh bundle exec jekyll build -cd test/browser +cd .github/browser-tests npm ci npx playwright install --only-shell chromium npm test diff --git a/_config.yml b/_config.yml index 647d2e5e..3c04c876 100644 --- a/_config.yml +++ b/_config.yml @@ -14,8 +14,6 @@ plugins: # Build settings markdown: kramdown -exclude: - - test/browser defaults: - values: author: "Chris Kenst"