#52566 closed defect (bug) (fixed)
wp_resource_hints() test failures when removing $pagenow global from get_home_url()
| Reported by: | SergeyBiryukov | Owned by: | SergeyBiryukov |
|---|---|---|---|
| Priority: | normal | Milestone: | 5.7 |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: |
Description
Background: #52421
After [50156], there were two test failures:
1) Tests_WP_Resource_Hints::test_dns_prefetch_scripts_does_not_included_registered_only Undefined index: pagenow /var/www/build/wp-includes/functions.wp-scripts.php:272 /var/www/tests/phpunit/tests/general/resourceHints.php:192 2) Tests_WP_Resource_Hints::test_deregistered_scripts_are_ignored Undefined index: pagenow /var/www/build/wp-includes/functions.wp-scripts.php:272 /var/www/tests/phpunit/tests/general/resourceHints.php:205
Restoring the $pagenow global in [50164] have fixed them, but it's not quite clear why that happens, as the global is no longer used in the get_home_url() function.
As noted by @peterwilsoncc in comment:9:ticket:52421, this could be either a poorly defined global in source, or erroneously reset global in the tests.
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
In 50393: