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

Side by Side Diff: third_party/WebKit/LayoutTests/webaudio/MediaElementAudioSource/mediaelementaudiosourcenode.html

Issue 2825113002: Add [SameObject] for Media{Element,Stream}AudioSourceNode (Closed)
Patch Set: Remove console.logs Created 3 years, 8 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/LayoutTests/webaudio/MediaStreamAudioSource/mediastreamaudiosourcenode.html » ('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 2
3 <html> 3 <html>
4 <head> 4 <head>
5 <script src="../../resources/testharness.js"></script> 5 <script src="../../resources/testharness.js"></script>
6 <script src="../../resources/testharnessreport.js"></script> 6 <script src="../../resources/testharnessreport.js"></script>
7 <script src="../resources/audit-util.js"></script> 7 <script src="../resources/audit-util.js"></script>
8 <script src="../resources/audit.js"></script> 8 <script src="../resources/audit.js"></script>
9 </head> 9 </head>
10 10
(...skipping 25 matching lines...) Expand all
36 .throw('TypeError'); 36 .throw('TypeError');
37 should( 37 should(
38 () => audioNode.connect(context.destination, 5, 0), 38 () => audioNode.connect(context.destination, 5, 0),
39 'audioNode.connect(context.destination, 5, 0)') 39 'audioNode.connect(context.destination, 5, 0)')
40 .throw('IndexSizeError'); 40 .throw('IndexSizeError');
41 should( 41 should(
42 () => audioNode.connect(context.destination, 0, 5), 42 () => audioNode.connect(context.destination, 0, 5),
43 'audioNode.connect(context.destination, 0, 5)') 43 'audioNode.connect(context.destination, 0, 5)')
44 .throw('IndexSizeError'); 44 .throw('IndexSizeError');
45 45
46 // Verify same object is returned.
47 let element = mediaSource.mediaElement;
48 should(element instanceof HTMLMediaElement,
49 'mediaSource.mediaElement instanceof HTMLMediaElement')
50 .beTrue();
51 should(mediaSource.mediaElement === element,
52 'mediaSource.mediaElement is same object')
53 .beTrue();
54
46 // Try calling connect() with proper values. 55 // Try calling connect() with proper values.
47 should( 56 should(
48 () => audioNode.connect(context.destination, 0, 0), 57 () => audioNode.connect(context.destination, 0, 0),
49 'audioNode.connect(context.destination, 0, 0)') 58 'audioNode.connect(context.destination, 0, 0)')
50 .notThrow(); 59 .notThrow();
51 60
52 // Try creating another MediaElementAudioSourceNode using the same audio 61 // Try creating another MediaElementAudioSourceNode using the same audio
53 // element. 62 // element.
54 should( 63 should(
55 () => context.createMediaElementSource(audioElement), 64 () => context.createMediaElementSource(audioElement),
56 'context.createMediaElementSource(audioElement)') 65 'context.createMediaElementSource(audioElement)')
57 .throw(); 66 .throw();
58 67
59 task.done(); 68 task.done();
60 }); 69 });
61 70
62 audit.run(); 71 audit.run();
63 72
64 </script> 73 </script>
65 74
66 </body> 75 </body>
67 </html> 76 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/webaudio/MediaStreamAudioSource/mediastreamaudiosourcenode.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698