ci(accessibility-report): generate a report of full and partial accessibility violations#7962
Draft
sianford wants to merge 1 commit into
Draft
ci(accessibility-report): generate a report of full and partial accessibility violations#7962sianford wants to merge 1 commit into
sianford wants to merge 1 commit into
Conversation
| const htmlPath = path.join(this.outputDir, "accessibility-report.html"); | ||
| fs.writeFileSync(htmlPath, this.generateHTML()); | ||
|
|
||
| // eslint-disable-next-line no-console |
Contributor
There was a problem hiding this comment.
suggestion: You might be better of just disabling the console stuff for the full file rather than line by line.
84eaa1d to
4af6e72
Compare
DipperTheDan
approved these changes
Jun 3, 2026
paulrobinson88
approved these changes
Jun 4, 2026
Contributor
There was a problem hiding this comment.
Looks good to me Sian, not sure if it's possible, but it would be handy if the search could be filtered to component only. For example, if I want to show only violations for the Menu component, searching for the word 'menu' will bring up any tests or components that include the word menu, like action-popover otherwise I think it will be very useful to us, plus we could filter by component in Excel using the csv I guess.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed behaviour
Generate a report of failed and incomplete accessibility issues in HTML file
playwright/test-report/accessibility-report.htmlwhen Playwright is run in CI mode. The HTML file should be opened in a browser by the user, providing a UI containing the following:The report is deleted each time the Playwright suite is run.
The Playwright README.md file is updated with details of where to find the report.
HTML opened in the browser:
Data downloaded as CSV:
Current behaviour
Incomplete accessibility checks report out in the console when the Playwright regresson suite is run in CI mode, as below:
Unlike full accessibility failures, these do not report out in the Playwright run report.
Checklist
d.tsfile added or updated if requiredQA
Additional context
A solution was initially provided in the form of JSON attachments (PR: #7647). However, this was not easy for QAs to extract the required information from which to log bugs, so a different solution was sought.
Testing instructions
npm install.npm run test:ct.playwright/test-report.accessibility-report.htmlin a browser, either directly from VS Code or via your carbon directory structure on your machine.