1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/browser/devtools/shadereditor/test/browser_webgl-actor-test-11.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,25 @@ 1.4 +/* Any copyright is dedicated to the Public Domain. 1.5 + http://creativecommons.org/publicdomain/zero/1.0/ */ 1.6 + 1.7 +/** 1.8 + * Tests if the WebGL context is never instrumented anymore after the 1.9 + * finalize method is called. 1.10 + */ 1.11 + 1.12 +function ifWebGLSupported() { 1.13 + let [target, debuggee, front] = yield initBackend(SIMPLE_CANVAS_URL); 1.14 + 1.15 + let linked = once(front, "program-linked"); 1.16 + front.setup({ reload: true }); 1.17 + yield linked; 1.18 + ok(true, "Canvas was correctly instrumented on the first navigation."); 1.19 + 1.20 + once(front, "program-linked").then(() => { 1.21 + ok(false, "A 'program-linked' notification shouldn't have been sent!"); 1.22 + }); 1.23 + 1.24 + yield front.finalize(); 1.25 + yield reload(target); 1.26 + yield removeTab(target.tab); 1.27 + finish(); 1.28 +}