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

Unified Diff: chrome/test/data/nacl/postmessage_redir/pm_redir_test.html

Issue 513273003: Drop NaCl support for posting stdout/stderr to JS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Back out documentation changes. Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/data/nacl/postmessage_redir/pm_redir_test.cc ('k') | chrome/test/nacl/nacl_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/nacl/postmessage_redir/pm_redir_test.html
diff --git a/chrome/test/data/nacl/postmessage_redir/pm_redir_test.html b/chrome/test/data/nacl/postmessage_redir/pm_redir_test.html
deleted file mode 100644
index ee2de323d910d73b5cbb14000e843ca88063e743..0000000000000000000000000000000000000000
--- a/chrome/test/data/nacl/postmessage_redir/pm_redir_test.html
+++ /dev/null
@@ -1,99 +0,0 @@
-<!--
- Copyright 2013 The Chromium Authors. All rights reserved.
- Use of this source code is governed by a BSD-style license that can
- be found in the LICENSE file.
--->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
- <head>
- <meta http-equiv="Pragma" content="no-cache" />
- <meta http-equiv="Expires" content="-1" />
- <script type="text/javascript" src="nacltest.js"></script>
- <title>Native Client I/O Redirection to Post Message Test</title>
- </head>
-
- <body>
- <h1>Native Client I/O Redirection to Post Message Test</h1>
- <div>
-
- <script type="text/javascript">
- //<![CDATA[
-function createModule(id, src, type) {
- return createNaClEmbed({
- id: id,
- src: src,
- width: 400,
- height: 400,
- type: type
- });
-}
-
-var mime = 'application/x-nacl';
-if (getTestArguments()['pnacl'] !== undefined) {
- mime = 'application/x-pnacl';
-}
-var embed = createModule('naclModule', 'pm_redir_test.nmf', mime);
-embed.basic_tests ='2';
-embed.stress_tests = '0';
-document.body.appendChild(embed);
-
-function setupTests(tester, plugin) {
- tester.addAsyncTest('Test_output', function(status) {
- plugin.addEventListener('message', function(message_event) {
- var prefix = 'DEBUG_POSTMESSAGE:';
- if (message_event.data.indexOf(prefix) == 0) {
- var expected_output = 'BOGUS STRING';
- if (args.stream == 'stdout' && args.thread == 'fg') {
- expected_output =
- ('In the year 1878 I took my degree of Doctor of Medicine...\n');
- } else if (args.stream == 'stderr' && args.thread == 'fg') {
- expected_output =
- ('A merry little surge of electricity piped by automatic'
- +' alarm...\n');
- } else if (args.stream == 'stdout' && args.thread == 'bg') {
- expected_output =
- ('Squire Trelawney, Dr. Livesey, and the rest of these'
- +' gentlemen...\n');
- } else if (args.stream == 'stderr' && args.thread == 'bg') {
- expected_output =
- ('It is a truth universally acknowledged, that a single man'
- +' in possession...\n');
- }
- var msg_string = message_event.data.substring(prefix.length);
- console.log('expected output ' + expected_output);
-
- console.log(msg_string);
- if (msg_string == expected_output) {
- console.log('pass!');
- this.removeEventListener('message', arguments.callee, true);
- status.pass();
- } else {
- // comment this out if test framework args=['--debug'] is
- // used, since that causes lots of SRPC and PPAPI_PROXY
- // debug output to be generated on stdout/err, and the test
- // has no debugging output
- //
- status.fail('unexpected output: ' + msg_string);
- }
- }
- }, true);
- message=('stream=' + args.stream + ',thread=' + args.thread +
- ',delay_us=' + args.delay_us);
-console.log(message);
- plugin.postMessage(message);
- });
-}
-
-var tester = new Tester();
-var args = getTestArguments({
- 'stream' : 'THIS TEST CANNOT RUN STANDALONE -- run using scons instead',
- 'thread' : 'THIS TEST CANNOT RUN STANDALONE -- run using scons instead',
-});
-setupTests(tester, $('naclModule'));
-tester.waitFor($('naclModule'));
-tester.run();
- //]]>
- </script>
- </body>
-</html>
« no previous file with comments | « chrome/test/data/nacl/postmessage_redir/pm_redir_test.cc ('k') | chrome/test/nacl/nacl_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698