Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integrate Pa11y Automated Accessibility Testing #1138

Draft
wants to merge 3 commits into
base: development
Choose a base branch
from

Conversation

kivuvarosekivuvan
Copy link
Contributor

@kivuvarosekivuvan kivuvarosekivuvan commented Jul 3, 2024

Description

  • To improve the accessibility of our platform and ensure that all contributors' code meets the required standards, this pull request integrates the Pa11y automated accessibility testing tool into our development workflow.

NOTE: This is something that I am still trying to figure out, things like testing for a modal/components we have because at the moment this can test the page individually with the different commands provided to test each page, however I'm open to receive any comment

Key Changes

  • Install Pa11y: Pa11y is installed as a development dependency in the project using the command npm install pa11y --save-dev.
  • Creating Pa11y Configuration File: A new file pa11y.config.js is added in the root of the project, which contains the configuration options for the Pa11y tests. This includes settings such as the timeout, headers, logging, and the WCAG standard to be used.
  • Integrate Pa11y into the Build Process: Scripts are added ( "test:map": "pa11y --config pa11y.config.js 'http://localhost:4200/map'",
    "test:feed": "pa11y --config pa11y.config.js 'http://localhost:4200/feed'",
    "test:activity": "pa11y --config pa11y.config.js 'http://localhost:4200/activity'",
    "test:general": "pa11y --config pa11y.config.js 'http://localhost:4200/settings/general'",)
  • Document on the Integration Steps: Getting started

Screenshot

Screenshot from 2024-07-03 14-54-32

Copy link
Member

@Ifycode Ifycode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kivuvarosekivuvan nice work on integrating pally.

I have left some comments for here on this PR, and some in slack.

@@ -34,7 +34,6 @@
"@supy-io/ngx-intercom": "^14.2.12",
"@swimlane/ngx-charts": "^20.1.2",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kivuvarosekivuvan for the package-lock.json file, let's approach it like this to resolve conflicts. And also because the package-lock.json shouldn't even be showing up here since it's generated (maintainers will do that work of generating it for contributors).

Restore the package-lock.json to original, the add and commit only the package-lock file, then push.

If your package-lock file changes again, just ensure not to add, commit and push it along with the other the files you have worked on.

@Angamanga
Copy link
Contributor

@kivuvarosekivuvan This is really, really useful! Do you think there is other useful commands we could use? Maybe a custom-command where one can paste in the url to test. Like npm run test:custom http://localhost:4200/feed/108356/view?page=1&mode=POST Not sure if that would work but I think it could be an interesting thing.

@kivuvarosekivuvan
Copy link
Contributor Author

@Angamanga Sure, I can definitively try this

ROSE added 2 commits July 23, 2024 08:28
Implemented a new custom command that allows users to test a specified URL
@kivuvarosekivuvan kivuvarosekivuvan marked this pull request as draft August 5, 2024 10:33
@kivuvarosekivuvan kivuvarosekivuvan self-assigned this Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants