Opened 5 years ago
Last modified 16 months ago
#48229 new defect (bug)
Console error when running QUnit Test Suite
Reported by: | Hareesh Pillai | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | minor | Version: | |
Component: | Build/Test Tools | Keywords: | close |
Focuses: | Cc: |
Description
There is a 404 (Not Found) error reported in the browser console for the admin-ajax.php
file while running QUnit Test Suite.
After selectively running the tests, I could narrow it down to the image widget control tests in the Image Media Widget
module.
Although all the tests are passing, this error should be fixed.
Attachments (1)
Change History (6)
This ticket was mentioned in Slack in #core-js by hareesh-pillai. View the logs.
5 years ago
#2
@
4 years ago
- Keywords reporter-feedback added
Hi Hareesh 👋🏻
It's working for me now, are you still seeing that error?
If so, it could be a routing issue with your web server, since the tests are setup a little weird. Here's my Nginx config:
server { listen 80; server_name wp-develop.test; root /Users/ian-work/vhosts/localhost/wp-develop.test/public_html/build; location /tests/ { root /Users/ian-work/vhosts/localhost/wp-develop.test/public_html/; try_files $uri $uri/ /wordpress/$uri /wordpress/index.php?$args; } # this is also necessary for qunit location /node_modules/ { root /Users/ian-work/vhosts/localhost/wp-develop.test/public_html/; try_files $uri $uri/ /wordpress/$uri /wordpress/index.php?$args; } }
If routing isn't the problem, you could try opening them directly in your browser, with a URL like file:///Users/myusername/dev/develop.svn.wordpress.org/trunk/tests/qunit/index.html
#3
@
4 years ago
- Keywords reporter-feedback removed
Thanks for the comment @iandunn.
I still see the same error while running the tests from localhost. However, when I try running directly with the URL like you suggested, there is no console error.
Screenshot of the console error