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

Unified Diff: LayoutTests/webmidi/open_close.html

Issue 1041213004: Web MIDI API: update open() and close() implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@midi_wd
Patch Set: fix rebase errors Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/webmidi/open_close-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/webmidi/open_close.html
diff --git a/LayoutTests/webmidi/open_close.html b/LayoutTests/webmidi/open_close.html
index 8f6bcb405d0b51b8a41b37dc0e6ae31997a50f1f..98b414bfbe4d44e6266ee6437d18e17bc796f2f2 100644
--- a/LayoutTests/webmidi/open_close.html
+++ b/LayoutTests/webmidi/open_close.html
@@ -13,8 +13,7 @@ function checkStateTransition(options) {
debug("- check initial state.");
window.port = options.port;
shouldBeEqualToString("port.connection", options.initialconnection);
- port.onstatechange = function(e) {
- debug("- check handler port.");
+ checkHandler = function(e) {
yhirano 2015/03/31 07:27:20 var
Takashi Toyoshima 2015/03/31 11:22:02 Done.
window.eventport = e.port;
testPassed("handler is called with port " + eventport + ".");
if (options.initialconnection == options.finalconnection) {
@@ -23,6 +22,14 @@ function checkStateTransition(options) {
shouldBeEqualToString("eventport.id", options.port.id);
shouldBeEqualToString("eventport.connection", options.finalconnection);
};
+ port.onstatechange = function(e) {
+ debug("- check port handler.");
+ checkHandler(e);
+ };
+ access.onstatechange = function(e) {
+ debug("- check access handler.");
+ checkHandler(e);
+ };
return port[options.method]().then(function(p) {
window.callbackport = p;
debug("- check callback arguments.");
« no previous file with comments | « no previous file | LayoutTests/webmidi/open_close-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698