-
Notifications
You must be signed in to change notification settings - Fork 66
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
Prepending base URL #195
Comments
Never mind. I just found sitemap-find and sitemap-replace. Still, for some reason pa11y is checking the xml file instead of running it as a sitemap.
It should be checking ousite.docksal.site and oursite.docksal.site/contact, but it's checking oursite.docksal.site and pa11y.xml. Am I calling for the sitemap wrong? |
So it seems to not be using the --sitemap argument. It thinks the xml is a page. When I add an = sign in, I just get nothing instead.
Adding -vvv seems to just give the version instead of verbose output. Edit: looks like -d gets me verbose output but nothing seems to indicate why it's busted. I did fix/ensure my xml and it is valid. |
I installed pa11y globally and tried running it with the pa11y-ci command instead of through npm.
With this response:
Which doesn't make much sense because my browser clearly displays the valid xml. |
Hi @loopy3025 The sitemap that you're trying to use doesn't seem to exist, or if it does, it's not publicly available: $ curl -I "https://dev.docksal.site/themes/custom/dev/pa11y/pa11y-sitemap.xml"
curl: (28) Failed to connect to dev.docksal.site port 443 after 129492 ms: Connection timed out I don't think your problem is related to pa11y. |
It's not public. It's on my local. I have removed some of the parts of the URL because I don't want to expose these sorts of things publicly. This is what's displayed in my browser at the xml location:
However, you did help me out a bit. I CURLed the URL and got
I've never had an issue like this on this machine before, but then again I don't think I've ever tried parsing a local xml file through the command line through a url before. It sure would be easier to specify a file location instead of a url. At any rate, I'll push the file to the server and reference that one instead, I guess. |
After working with this for a few days, I believe it would be a huge benefit if pa11y had a --run-local or --run-dev flag which would run the curl of the xml file as --insecure. Here's my solution in case anyone is looking for a similar solution where they want to test during ci or manually on a website with multiple environments. This specific example is drupal on acquia cloud. This does not fail the test if pages fail, but does write a report. .pa11yci.js:
The Script .accessibility-test.sh
acquia-pipelines.yml during setup-env
blt.yml
|
We are running pa11y through a bash script. We would like to run pa11y not only on ci, but locally, and on every environment (dev, stage, and prod). Currently, it seems I have to run pa11y using a different sitemap for each environment or, alternatively, run a separate pa11y test for each url in a loop and put in the base url with an argument for my bash function.
I'd like to be able to do one of three things:
npm run tests --sitemap sitemap.xml --baseurl https://baseurl.dev.com
or,npm run tests $pagelist
where $pagelist can be multiple pages instead of just one, orThe text was updated successfully, but these errors were encountered: