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

Unified Diff: LayoutTests/webaudio/audionode.html

Issue 14028011: Made AudioNode an EventTarget (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/webaudio/audionode-expected.txt » ('j') | Source/modules/webaudio/AudioNode.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/webaudio/audionode.html
diff --git a/LayoutTests/webaudio/audionode.html b/LayoutTests/webaudio/audionode.html
index dd0dc32958a5ed2f8d7baf4c4d64de134ad7f524..5fdcfd0707648a042835b6405ac8faa28b38f0a5 100644
--- a/LayoutTests/webaudio/audionode.html
+++ b/LayoutTests/webaudio/audionode.html
@@ -101,6 +101,18 @@ function runTest() {
testPassed("exception thrown when creating audio context with not enough arguments.");
}
+ // Ensure it is an EventTarget
+ try {
+ window.audioNodeIsEventTarget = false;
+ audioNode.addEventListener('testEvent', function(){
+ audioNodeIsEventTarget = true;
+ });
+ audioNode.dispatchEvent(new Event('testEvent'));
+ shouldBeTrue('audioNodeIsEventTarget');
haraken 2013/04/15 00:01:25 Nit: You can write testPassed() line inside the ev
+ } catch(e) {
+ testFailed("exception shouldn't be thrown when testing whether audio node is an event target");
+ }
+
finishJSTest();
}
« no previous file with comments | « no previous file | LayoutTests/webaudio/audionode-expected.txt » ('j') | Source/modules/webaudio/AudioNode.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698