Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Unified Diff: third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html

Issue 2084053002: EME: Update tests so 'audioCapabilities' always provided (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changes (+rebase) Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html
diff --git a/third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html b/third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html
index e51597f25241e1376b342519adc7d2e865bd1efb..50dbd1d0500a1fd7a1b557e778490d806eaa1990 100644
--- a/third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html
+++ b/third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-unique-origin.html
@@ -35,7 +35,13 @@
var script = 'data:text/html,' +
'<script>' +
' window.onmessage = function(e) {' +
- ' navigator.requestMediaKeySystemAccess(\'org.w3.clearkey\', [{}]).then(function(access) {' +
+ ' navigator.requestMediaKeySystemAccess(\'org.w3.clearkey\', [{' +
+ ' initDataTypes: [ \'keyids\' ],' +
+ ' audioCapabilities: [' +
+ ' { contentType: \'audio/mp4; codecs="mp4a.40.2"\' },' +
+ ' { contentType: \'audio/webm; codecs="opus"\' }' +
+ ' ]' +
+ ' }]).then(function(access) {' +
' return access.createMediaKeys();' +
' }).then(function(mediaKeys) {' +
' window.parent.postMessage({result: \'allowed\'}, \'*\');' +
@@ -46,7 +52,13 @@
'<\/script>';
// Verify that this page can create a MediaKeys first.
- navigator.requestMediaKeySystemAccess('org.w3.clearkey', [{}]).then(function(access) {
+ navigator.requestMediaKeySystemAccess('org.w3.clearkey', [{
+ initDataTypes: [ 'keyids' ],
+ audioCapabilities: [
+ { contentType: 'audio/mp4; codecs="mp4a.40.2"' },
+ { contentType: 'audio/webm; codecs="opus"' }
+ ]
+ }]).then(function(access) {
return access.createMediaKeys();
}).then(function(mediaKeys) {
// Success, so now create the iframe and try there.

Powered by Google App Engine
This is Rietveld 408576698