Skip to content

Unit tests are broken on WordPress trunk due to loading=lazy #4563

@westonruter

Description

@westonruter

Bug Description

These tests are currently failing in WordPress trunk due to the introduction of loading=lazy (see r47554):

1) AMP_Gallery_Embed_Handler_Test::test__conversion with data set "shortcode_with_lightbox" ('[gallery amp-lightbox=true am...id3}}]', '<style type='text/css'> #gall...</div>')
2) AMP_Gallery_Embed_Handler_Test::test__conversion with data set "shortcode_with_lightbox_linking_to_file" ('[gallery amp-lightbox=true am...id3}}]', '<style type='text/css'> #gall...</div>')
3) Test_AMP_YouTube_Embed_Handler::test__conversion with data set "url_simple" ('https://www.youtube.com/watch...bJY0\n', '<p><amp-youtube data-videoid=...</p>\n', '<p><amp-youtube data-videoid=...</p>\n')
4) Test_AMP_YouTube_Embed_Handler::test__conversion with data set "url_short" ('https://youtu.be/kfVsfOSbJY0\n', '<p><amp-youtube data-videoid=...</p>\n', '<p><amp-youtube data-videoid=...</p>\n')
5) Test_AMP_YouTube_Embed_Handler::test__conversion with data set "url_with_querystring" ('http://www.youtube.com/watch?...=349\n', '<p><amp-youtube data-videoid=...</p>\n', '<p><amp-youtube data-videoid=...</p>\n')
6) Test_AMP_YouTube_Embed_Handler::test__conversion with data set "embed_url" ('https://www.youtube.com/embed...bJY0\n', '<p><amp-youtube data-videoid=...</p>\n', '<p><amp-youtube data-videoid=...</p>\n')
7) Test_AMP_Validation_Manager::test_decorate_shortcode_and_filter_source

Expected Behaviour

You shall not fail!


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

Implementation brief

QA testing instructions

Demo

Changelog entry

Metadata

Metadata

Assignees

Labels

BugSomething isn't workingTestingIssues related with Unit, E2E, Smoke, and other testing requirements/needs

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions