diff --git a/.github/actions/find/package-lock.json b/.github/actions/find/package-lock.json index 30e5e1d..6d59900 100644 --- a/.github/actions/find/package-lock.json +++ b/.github/actions/find/package-lock.json @@ -10,7 +10,7 @@ "license": "MIT", "dependencies": { "@actions/core": "^1.11.1", - "@axe-core/playwright": "^4.10.2", + "@axe-core/playwright": "^4.11.0", "playwright": "^1.56.1" }, "devDependencies": { @@ -54,12 +54,12 @@ "license": "MIT" }, "node_modules/@axe-core/playwright": { - "version": "4.10.2", - "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.10.2.tgz", - "integrity": "sha512-6/b5BJjG6hDaRNtgzLIfKr5DfwyiLHO4+ByTLB0cJgWSM8Ll7KqtdblIS6bEkwSF642/Ex91vNqIl3GLXGlceg==", + "version": "4.11.0", + "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.11.0.tgz", + "integrity": "sha512-70vBT/Ylqpm65RQz2iCG2o0JJCEG/WCNyefTr2xcOcr1CoSee60gNQYUMZZ7YukoKkFLv26I/jjlsvwwp532oQ==", "license": "MPL-2.0", "dependencies": { - "axe-core": "~4.10.3" + "axe-core": "~4.11.0" }, "peerDependencies": { "playwright-core": ">= 1.0.0" @@ -85,9 +85,9 @@ } }, "node_modules/axe-core": { - "version": "4.10.3", - "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.10.3.tgz", - "integrity": "sha512-Xm7bpRXnDSX2YE2YFfBk2FnF0ep6tmG7xPh8iHee8MIcrgq762Nkce856dYtJYLkuIoYZvGfTs/PbZhideTcEg==", + "version": "4.11.0", + "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.11.0.tgz", + "integrity": "sha512-ilYanEU8vxxBexpJd8cWM4ElSQq4QctCLKih0TSfjIfCQTeyH/6zVrmIJfLPrKTKJRbiG+cfnZbQIjAlJmF1jQ==", "license": "MPL-2.0", "engines": { "node": ">=4" diff --git a/.github/actions/find/package.json b/.github/actions/find/package.json index f0c65da..2158ad8 100644 --- a/.github/actions/find/package.json +++ b/.github/actions/find/package.json @@ -14,7 +14,7 @@ "type": "module", "dependencies": { "@actions/core": "^1.11.1", - "@axe-core/playwright": "^4.10.2", + "@axe-core/playwright": "^4.11.0", "playwright": "^1.56.1" }, "devDependencies": { diff --git a/tests/site-with-errors.test.ts b/tests/site-with-errors.test.ts index 83457c6..f670b4e 100644 --- a/tests/site-with-errors.test.ts +++ b/tests/site-with-errors.test.ts @@ -17,11 +17,15 @@ describe("site-with-errors", () => { it("cache has expected results", () => { const actual = results.map(({ issue: { url: issueUrl }, pullRequest: { url: pullRequestUrl }, findings }) => { - const { solutionLong, ...finding } = findings[0]; + const { problemUrl, solutionLong, ...finding } = findings[0]; // Check volatile fields for existence only expect(issueUrl).toBeDefined(); expect(pullRequestUrl).toBeDefined(); + expect(problemUrl).toBeDefined(); expect(solutionLong).toBeDefined(); + // Check `problemUrl`, ignoring axe version + expect(problemUrl.startsWith("https://dequeuniversity.com/rules/axe/")).toBe(true); + expect(problemUrl.endsWith(`/${finding.ruleId}?application=playwright`)).toBe(true); return finding; }); const expected = [ @@ -30,7 +34,6 @@ describe("site-with-errors", () => { url: "http://127.0.0.1:4000/", html: 'Jul 30, 2025', problemShort: "elements must meet minimum color contrast ratio thresholds", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/color-contrast?application=playwright", ruleId: "color-contrast", solutionShort: "ensure the contrast between foreground and background colors meets wcag 2 aa minimum contrast ratio thresholds" }, { @@ -38,7 +41,6 @@ describe("site-with-errors", () => { url: "http://127.0.0.1:4000/", html: '', problemShort: "page should contain a level-one heading", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/page-has-heading-one?application=playwright", ruleId: "page-has-heading-one", solutionShort: "ensure that the page, or at least one of its frames contains a level-one heading" }, { @@ -47,7 +49,6 @@ describe("site-with-errors", () => { html: ``, problemShort: "elements must meet minimum color contrast ratio thresholds", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/color-contrast?application=playwright", ruleId: "color-contrast", solutionShort: "ensure the contrast between foreground and background colors meets wcag 2 aa minimum contrast ratio thresholds", }, { @@ -55,7 +56,6 @@ describe("site-with-errors", () => { url: "http://127.0.0.1:4000/about/", html: 'jekyllrb.com', problemShort: "elements must meet minimum color contrast ratio thresholds", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/color-contrast?application=playwright", ruleId: "color-contrast", solutionShort: "ensure the contrast between foreground and background colors meets wcag 2 aa minimum contrast ratio thresholds", }, { @@ -63,7 +63,6 @@ describe("site-with-errors", () => { url: "http://127.0.0.1:4000/404.html", html: '
  • Accessibility Scanner Demo
  • ', problemShort: "elements must meet minimum color contrast ratio thresholds", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/color-contrast?application=playwright", ruleId: "color-contrast", solutionShort: "ensure the contrast between foreground and background colors meets wcag 2 aa minimum contrast ratio thresholds" }, { @@ -71,7 +70,6 @@ describe("site-with-errors", () => { url: "http://127.0.0.1:4000/404.html", html: '

    ', problemShort: "headings should not be empty", - problemUrl: "https://dequeuniversity.com/rules/axe/4.10/empty-heading?application=playwright", ruleId: "empty-heading", solutionShort: "ensure headings have discernible text", },