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

Side by Side Diff: third_party/WebKit/LayoutTests/media/encrypted-media/encrypted-media-requestmediakeysystemaccess.html

Issue 2736283002: Allow ParsedContentType to reject multiple definitions of the same parameter (Closed)
Patch Set: check first Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/encryptedmedia/NavigatorRequestMediaKeySystemAccess.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <title>Test navigator.requestMediaKeySystemAccess()</title> 4 <title>Test navigator.requestMediaKeySystemAccess()</title>
5 <script src="encrypted-media-utils.js"></script> 5 <script src="encrypted-media-utils.js"></script>
6 <script src="../../resources/testharness.js"></script> 6 <script src="../../resources/testharness.js"></script>
7 <script src="../../resources/testharnessreport.js"></script> 7 <script src="../../resources/testharnessreport.js"></script>
8 </head> 8 </head>
9 <body> 9 <body>
10 <script> 10 <script>
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 }], 'NotSupportedError', 'Codec is case-sensitive'); 307 }], 'NotSupportedError', 'Codec is case-sensitive');
308 308
309 // Unrecognized attributes are not allowed. 309 // Unrecognized attributes are not allowed.
310 expect_error('org.w3.clearkey', [{ 310 expect_error('org.w3.clearkey', [{
311 videoCapabilities: [{contentType: 'video/webm; foo="bar"'}], 311 videoCapabilities: [{contentType: 'video/webm; foo="bar"'}],
312 }], 'NotSupportedError', 'Unrecognized foo'); 312 }], 'NotSupportedError', 'Unrecognized foo');
313 expect_error('org.w3.clearkey', [{ 313 expect_error('org.w3.clearkey', [{
314 videoCapabilities: [{contentType: 'video/webm; foo="bar"; codecs ="vp8"'}], 314 videoCapabilities: [{contentType: 'video/webm; foo="bar"; codecs ="vp8"'}],
315 }], 'NotSupportedError', 'Unrecognized foo with codecs'); 315 }], 'NotSupportedError', 'Unrecognized foo with codecs');
316 316
317 // Multiple parameters with the same name are not allowed (RFC6838).
318 expect_error('org.w3.clearkey', [{
319 videoCapabilities: [{contentType: 'video/webm; codecs=vp8; codec s=vp9'}],
320 }], 'NotSupportedError', 'Multiple codecs');
321
317 // Invalid contentTypes. 322 // Invalid contentTypes.
318 expect_error('org.w3.clearkey', [{ 323 expect_error('org.w3.clearkey', [{
319 videoCapabilities: [{contentType: 'fake'}], 324 videoCapabilities: [{contentType: 'fake'}],
320 }], 'NotSupportedError', 'contentType fake'); 325 }], 'NotSupportedError', 'contentType fake');
321 326
322 expect_error('org.w3.clearkey', [{ 327 expect_error('org.w3.clearkey', [{
323 audioCapabilities: [{contentType: 'audio/fake'}], 328 audioCapabilities: [{contentType: 'audio/fake'}],
324 }], 'NotSupportedError', 'contentType audio/fake'); 329 }], 'NotSupportedError', 'contentType audio/fake');
325 330
326 expect_error('org.w3.clearkey', [{ 331 expect_error('org.w3.clearkey', [{
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 }], 'NotSupportedError', 'persistent-license sessionType'); 370 }], 'NotSupportedError', 'persistent-license sessionType');
366 371
367 // Verify invalid sessionTypes. 372 // Verify invalid sessionTypes.
368 expect_error('org.w3.clearkey', [{ 373 expect_error('org.w3.clearkey', [{
369 sessionTypes: [ 'foo' ], 374 sessionTypes: [ 'foo' ],
370 audioCapabilities: [{contentType: 'audio/webm; codecs=vorbis'}] 375 audioCapabilities: [{contentType: 'audio/webm; codecs=vorbis'}]
371 }], 'NotSupportedError', 'invalid sessionType'); 376 }], 'NotSupportedError', 'invalid sessionType');
372 </script> 377 </script>
373 </body> 378 </body>
374 </html> 379 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/encryptedmedia/NavigatorRequestMediaKeySystemAccess.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698