From 43a97878ce14b72f0981164f87f2e35e14151312 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 11:22:09 +0200 Subject: Adding upstream version 110.0.1. Signed-off-by: Daniel Baumann --- .../web-platform/tests/remote-playback/META.yml | 4 ++ .../web-platform/tests/remote-playback/README.md | 14 +++++++ .../remote-playback/cancel-watch-availability.html | 44 ++++++++++++++++++++++ ...-playback-cancel-watch-availability-throws.html | 29 ++++++++++++++ .../disable-remote-playback-prompt-throws.html | 16 ++++++++ ...-remote-playback-watch-availability-throws.html | 17 +++++++++ .../tests/remote-playback/idlharness.window.js | 29 ++++++++++++++ .../remote-playback/prompt-in-detached-iframe.html | 17 +++++++++ .../watch-availability-initial-callback.html | 22 +++++++++++ 9 files changed, 192 insertions(+) create mode 100644 testing/web-platform/tests/remote-playback/META.yml create mode 100644 testing/web-platform/tests/remote-playback/README.md create mode 100644 testing/web-platform/tests/remote-playback/cancel-watch-availability.html create mode 100644 testing/web-platform/tests/remote-playback/disable-remote-playback-cancel-watch-availability-throws.html create mode 100644 testing/web-platform/tests/remote-playback/disable-remote-playback-prompt-throws.html create mode 100644 testing/web-platform/tests/remote-playback/disable-remote-playback-watch-availability-throws.html create mode 100644 testing/web-platform/tests/remote-playback/idlharness.window.js create mode 100644 testing/web-platform/tests/remote-playback/prompt-in-detached-iframe.html create mode 100644 testing/web-platform/tests/remote-playback/watch-availability-initial-callback.html (limited to 'testing/web-platform/tests/remote-playback') diff --git a/testing/web-platform/tests/remote-playback/META.yml b/testing/web-platform/tests/remote-playback/META.yml new file mode 100644 index 0000000000..a234398b8b --- /dev/null +++ b/testing/web-platform/tests/remote-playback/META.yml @@ -0,0 +1,4 @@ +spec: https://w3c.github.io/remote-playback/ +suggested_reviewers: + - mfoltzgoogle + - louaybassbouss diff --git a/testing/web-platform/tests/remote-playback/README.md b/testing/web-platform/tests/remote-playback/README.md new file mode 100644 index 0000000000..b934227593 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/README.md @@ -0,0 +1,14 @@ +# Remote Playback API specification Tests + +The Remote Playback API can be found here: + +GitHub repository: https://github.com/w3c/remote-playback/ + +File an issue: https://github.com/w3c/remote-playback/issues/new + +## Hardware/network dependency + +The Remote Playback API requires to communicate with a device over the network. +Some behavior would require a real devices to be implemented. In order to keep +these tests automated, only behaviors that can be run without user gesture or +specific configurations are available here. diff --git a/testing/web-platform/tests/remote-playback/cancel-watch-availability.html b/testing/web-platform/tests/remote-playback/cancel-watch-availability.html new file mode 100644 index 0000000000..d83c8cecb0 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/cancel-watch-availability.html @@ -0,0 +1,44 @@ + + +Tests various ways to call cancelWatchAvailability() + + + + + diff --git a/testing/web-platform/tests/remote-playback/disable-remote-playback-cancel-watch-availability-throws.html b/testing/web-platform/tests/remote-playback/disable-remote-playback-cancel-watch-availability-throws.html new file mode 100644 index 0000000000..bdd35d8101 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/disable-remote-playback-cancel-watch-availability-throws.html @@ -0,0 +1,29 @@ + + +Test that calling cancelWatchAvailability() when disableRemotePlayback attribute is set throws an exception + + + + + diff --git a/testing/web-platform/tests/remote-playback/disable-remote-playback-prompt-throws.html b/testing/web-platform/tests/remote-playback/disable-remote-playback-prompt-throws.html new file mode 100644 index 0000000000..18333842b6 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/disable-remote-playback-prompt-throws.html @@ -0,0 +1,16 @@ + + +Test that calling prompt() when disableRemotePlayback attribute is set throws an exception + + + + + diff --git a/testing/web-platform/tests/remote-playback/disable-remote-playback-watch-availability-throws.html b/testing/web-platform/tests/remote-playback/disable-remote-playback-watch-availability-throws.html new file mode 100644 index 0000000000..b671d9f944 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/disable-remote-playback-watch-availability-throws.html @@ -0,0 +1,17 @@ + + +Test that calling watchAvailability() when disableRemotePlayback attribute is set throws an exception + + + + + diff --git a/testing/web-platform/tests/remote-playback/idlharness.window.js b/testing/web-platform/tests/remote-playback/idlharness.window.js new file mode 100644 index 0000000000..458bfd0c60 --- /dev/null +++ b/testing/web-platform/tests/remote-playback/idlharness.window.js @@ -0,0 +1,29 @@ +// META: script=/resources/WebIDLParser.js +// META: script=/resources/idlharness.js +// META: script=/common/media.js +// META: timeout=long + +'use strict'; + +// https://w3c.github.io/remoteplayback/ + +idl_test( + ['remote-playback'], + ['html', 'dom'], + idl_array => { + try { + const media = document.createElement('video'); + media.src = getVideoURI('/media/movie_5'); + media.width = media.height = 10; + document.body.appendChild(media); + self.media = media; + } catch (e) { + // Will be surfaced when media is undefined below. + } + + idl_array.add_objects({ + HTMLVideoElement: ['media'], + RemotePlayback: ['media.remote'] + }); + } +); diff --git a/testing/web-platform/tests/remote-playback/prompt-in-detached-iframe.html b/testing/web-platform/tests/remote-playback/prompt-in-detached-iframe.html new file mode 100644 index 0000000000..501471755a --- /dev/null +++ b/testing/web-platform/tests/remote-playback/prompt-in-detached-iframe.html @@ -0,0 +1,17 @@ + + + + + + + diff --git a/testing/web-platform/tests/remote-playback/watch-availability-initial-callback.html b/testing/web-platform/tests/remote-playback/watch-availability-initial-callback.html new file mode 100644 index 0000000000..352321b06a --- /dev/null +++ b/testing/web-platform/tests/remote-playback/watch-availability-initial-callback.html @@ -0,0 +1,22 @@ + + +Test that the callback is called once watchAvailability() resolves. + + + + + -- cgit v1.2.3