From 6bf0a5cb5034a7e684dcc3500e841785237ce2dd Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 19:32:43 +0200 Subject: Adding upstream version 1:115.7.0. Signed-off-by: Daniel Baumann --- testing/web-platform/tests/mediasession/META.yml | 3 + testing/web-platform/tests/mediasession/README.md | 20 ++ .../mediasession/helper/artwork-generator.html | 18 ++ .../tests/mediasession/idlharness.window.js | 18 ++ .../tests/mediasession/mediametadata.html | 219 +++++++++++++++++++++ .../tests/mediasession/playbackstate.html | 27 +++ .../tests/mediasession/positionstate.html | 106 ++++++++++ .../tests/mediasession/setactionhandler.html | 34 ++++ .../tests/mediasession/setcameraactive.html | 12 ++ .../tests/mediasession/setmicrophoneactive.html | 12 ++ 10 files changed, 469 insertions(+) create mode 100644 testing/web-platform/tests/mediasession/META.yml create mode 100644 testing/web-platform/tests/mediasession/README.md create mode 100644 testing/web-platform/tests/mediasession/helper/artwork-generator.html create mode 100644 testing/web-platform/tests/mediasession/idlharness.window.js create mode 100644 testing/web-platform/tests/mediasession/mediametadata.html create mode 100644 testing/web-platform/tests/mediasession/playbackstate.html create mode 100644 testing/web-platform/tests/mediasession/positionstate.html create mode 100644 testing/web-platform/tests/mediasession/setactionhandler.html create mode 100644 testing/web-platform/tests/mediasession/setcameraactive.html create mode 100644 testing/web-platform/tests/mediasession/setmicrophoneactive.html (limited to 'testing/web-platform/tests/mediasession') diff --git a/testing/web-platform/tests/mediasession/META.yml b/testing/web-platform/tests/mediasession/META.yml new file mode 100644 index 0000000000..8eb7fa0261 --- /dev/null +++ b/testing/web-platform/tests/mediasession/META.yml @@ -0,0 +1,3 @@ +spec: https://w3c.github.io/mediasession/ +suggested_reviewers: + - mounirlamouri diff --git a/testing/web-platform/tests/mediasession/README.md b/testing/web-platform/tests/mediasession/README.md new file mode 100644 index 0000000000..7c7c9f8d57 --- /dev/null +++ b/testing/web-platform/tests/mediasession/README.md @@ -0,0 +1,20 @@ +# Media Session specification Tests + +The Media Session specification is available here: https://wicg.github.io/mediasession + +GitHub repository: https://github.com/WICG/mediasession + +File an issue: https://github.com/WICG/mediasession/issues/new + +## Device/system dependency + +The Media Session specification defines behaviors related to device or system +features such as the actions to run when a software/hardware media key is used. +These behaviors are not tested because they would depend on user agent specific +implementations and device specific features. + +## Status of these tests + +These tests are not complete and only reflect the Blink tests that could be +exported. If a reader find a behavior that could be tested and is not, they +should feel free to file a bug. diff --git a/testing/web-platform/tests/mediasession/helper/artwork-generator.html b/testing/web-platform/tests/mediasession/helper/artwork-generator.html new file mode 100644 index 0000000000..5a2fbb151d --- /dev/null +++ b/testing/web-platform/tests/mediasession/helper/artwork-generator.html @@ -0,0 +1,18 @@ + +MediaImage + diff --git a/testing/web-platform/tests/mediasession/idlharness.window.js b/testing/web-platform/tests/mediasession/idlharness.window.js new file mode 100644 index 0000000000..e4d914544e --- /dev/null +++ b/testing/web-platform/tests/mediasession/idlharness.window.js @@ -0,0 +1,18 @@ +// META: script=/resources/WebIDLParser.js +// META: script=/resources/idlharness.js + +// https://w3c.github.io/mediasession/ + +'use strict'; + +idl_test( + ['mediasession'], + ['html'], + idl_array => { + idl_array.add_objects({ + MediaMetadata: ['new MediaMetadata()'], + MediaSession: ['navigator.mediaSession'], + Navigator: ['navigator'] + }); + } +); diff --git a/testing/web-platform/tests/mediasession/mediametadata.html b/testing/web-platform/tests/mediasession/mediametadata.html new file mode 100644 index 0000000000..f87e71d969 --- /dev/null +++ b/testing/web-platform/tests/mediasession/mediametadata.html @@ -0,0 +1,219 @@ + +MediaMetadata interface + + + diff --git a/testing/web-platform/tests/mediasession/playbackstate.html b/testing/web-platform/tests/mediasession/playbackstate.html new file mode 100644 index 0000000000..63f3548d94 --- /dev/null +++ b/testing/web-platform/tests/mediasession/playbackstate.html @@ -0,0 +1,27 @@ + +MediaSession.playbackState attribute + + + diff --git a/testing/web-platform/tests/mediasession/positionstate.html b/testing/web-platform/tests/mediasession/positionstate.html new file mode 100644 index 0000000000..9141091a90 --- /dev/null +++ b/testing/web-platform/tests/mediasession/positionstate.html @@ -0,0 +1,106 @@ + +MediaSession.setPositionState + + + diff --git a/testing/web-platform/tests/mediasession/setactionhandler.html b/testing/web-platform/tests/mediasession/setactionhandler.html new file mode 100644 index 0000000000..a9df51968c --- /dev/null +++ b/testing/web-platform/tests/mediasession/setactionhandler.html @@ -0,0 +1,34 @@ + +Test that setting MediaSession event handler should notify the service + + + diff --git a/testing/web-platform/tests/mediasession/setcameraactive.html b/testing/web-platform/tests/mediasession/setcameraactive.html new file mode 100644 index 0000000000..d5cd6a93f1 --- /dev/null +++ b/testing/web-platform/tests/mediasession/setcameraactive.html @@ -0,0 +1,12 @@ + +MediaSession.setCameraActive + + + diff --git a/testing/web-platform/tests/mediasession/setmicrophoneactive.html b/testing/web-platform/tests/mediasession/setmicrophoneactive.html new file mode 100644 index 0000000000..fbb4c612d9 --- /dev/null +++ b/testing/web-platform/tests/mediasession/setmicrophoneactive.html @@ -0,0 +1,12 @@ + +MediaSession.setMicrophoneActive + + + -- cgit v1.2.3