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

Side by Side Diff: LayoutTests/plugins/return-negative-one-from-write.html

Issue 1319473007: Delete a bunch of NPAPI layout tests. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 5 years, 3 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script src="../resources/js-test.js"></script>
4 </head>
5 <body>
6 <p id="description"></p>
7 <div id="console"></div>
8
9 <script>
10 var newStreamCalled = false;
11 var destroyStreamCalled = false;
12
13 function main() {
14 if (!window.testRunner) {
15 debug("This test can only run from within DumpRenderTree, be cause it requires TestNetscapePlugin.\n");
16 return;
17 }
18 testRunner.waitUntilDone();
19 }
20
21 main();
22
23 function streamStarted() {
24 shouldBeFalse('newStreamCalled');
25 newStreamCalled = true;
26 }
27
28 function streamDestroyed(reason) {
29 window.reason = reason;
30
31 shouldBeTrue('newStreamCalled')
32 shouldBe('reason', '1');
33
34 debug('<br><span class="pass">TEST COMPLETE</span>');
35
36 testRunner.notifyDone();
37 }
38 </script>
39
40 <embed
41 type="application/x-webkit-test-netscape"
42 onStreamLoad="streamStarted()"
43 onStreamDestroy="streamDestroyed"
44 id="plugin">
45 </body>
46 <script>
47 description("This tests that NPP_DestroyStream is called with NPRES_NETW ORK_ERR not called if a plugin returns -1 its NPP_Write callback.");
48
49 var plugin = document.getElementById("plugin");
50
51 plugin.returnNegativeOneFromWrite = true;
52 shouldBeTrue("plugin.returnNegativeOneFromWrite");
53
54 plugin.getURLNotify("data:text/html,Test", null, "callback");
55 </script>
56 </html>
57
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698