ampproject / ampproject/amphtml
Use local iframe URL on 3p video player tests
- Dominant language
- JavaScript
- Stars
- 14.9k
- Forks
- 4.1k
- PR merge metrics
- No merged PRs in 30d
Description
Video player tests flake when the external URL loaded by the iframe fails to load.
Use a local URL for a blank document on unit tests instead when possible, like:
https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-delight-player/0.1/test/test-amp-delight-player.js#L53-L56
This is only required when a test waits for the iframe's document to load (for example, waiting for a successful `layoutCallback`).
### Progress
- [x] [~~amp-3q-player~~](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-3q-player/0.1/test/test-amp-3q-player.js) (not required)
- [x] [~~amp-brid-player~~](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-brid-player/0.1/test/test-amp-brid-player.js) (not required)
- [ ] [amp-brightcove](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-brightcove/0.1/test/test-amp-brightcove.js)
- [ ] [amp-dailymotion](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-dailymotion/0.1/test/test-amp-dailymotion.js)
- [x] [amp-delight-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-delight-player/0.1/test/test-amp-delight-player.js) (#31323)
- [ ] [amp-gfycat](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-gfycat/0.1/test/test-amp-gfycat.js)
- [ ] [amp-ima-video](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-ima-video/0.1/test/test-amp-ima-video.js)
- [ ] [amp-jwplayer](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-jwplayer/0.1/test/test-amp-jwplayer.js)
- [ ] [amp-minute-media-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-minute-media-player/0.1/test/test-amp-minute-media-player.js)
- [x] [amp-mowplayer](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-mowplayer/0.1/test/test-amp-mowplayer.js) (#31786)
- [x] [amp-nexxtv-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-nexxtv-player/0.1/test/test-amp-nexxtv-player.js) (#31786)
- [ ] [amp-ooyala-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-ooyala-player/0.1/test/test-amp-ooyala-player.js)
- [ ] [amp-powr-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-powr-player/0.1/test/test-amp-powr-player.js)
- [ ] [amp-redbull-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-redbull-player/0.1/test/test-amp-redbull-player.js)
- [ ] [amp-vimeo](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-vimeo/0.1/test/test-amp-vimeo.js)
- [ ] [amp-viqeo-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-viqeo-player/0.1/test/test-amp-viqeo-player.js)
- [ ] [amp-wistia-player](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-wistia-player/0.1/test/test-amp-wistia-player.js)
- [ ] [amp-youtube](https://github.com/ampproject/amphtml/blob/973d21cdd23cf87c0a2fe0536c441a67a33a0ff1/extensions/amp-youtube/0.1/test/test-amp-youtube.js)
Contributor guide
Assessment
This issue has not been assessed yet.