Roll leveldb 3f7758:803d69 (v1.17 -> v1.18)
[chromium-blink-merge.git] / chrome / test / data / nacl / manifest_file / irt_manifest_file_test.html
blobbd1f32b888ca871ac33952ec34554c08399aebe1
1 <!--
2 Copyright 2014 The Chromium Authors. All rights reserved.
3 Use of this source code is governed by a BSD-style license that can
4 be found in the LICENSE file.
5 -->
6 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
7 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
8 <html>
9 <head>
10 <meta http-equiv="Pragma" content="no-cache" />
11 <meta http-equiv="Expires" content="-1" />
12 <script type="text/javascript" src="nacltest.js"></script>
13 <title>Native Client Open Resource Before PPAPI Test</title>
14 </head>
16 <body>
17 <h1>Native Client Open Resource Before PPAPI Test</h1>
19 <script type="text/javascript">
20 //<![CDATA[
21 function createModule(id, src, type) {
22 return createNaClEmbed({
23 id: id,
24 src: src,
25 width: 400,
26 height: 400,
27 type: type
28 });
30 var mime = 'application/x-nacl';
31 if (getTestArguments()['pnacl'] !== undefined) {
32 mime = 'application/x-pnacl';
34 var embed = createModule('naclModule', 'irt_manifest_file.nmf', mime);
35 embed.basic_tests ='2';
36 embed.stress_tests = '0';
37 document.body.appendChild(embed);
39 function setupTests(tester, plugin) {
40 tester.addAsyncTest('Test_00_Init', function(status) {
41 plugin.addEventListener('message', function(message_event) {
42 this.removeEventListener('message', arguments.callee, false);
43 // When a test succeeds, 'Pass' is returned. There are six test cases.
44 var golden = ['Pass', 'Pass', 'Pass', 'Pass', 'Pass', 'Pass'];
45 status.assertEqual(message_event.data, golden);
46 status.pass();
47 }, false);
48 plugin.postMessage('hello');
49 });
52 var tester = new Tester();
53 setupTests(tester, $('naclModule'));
54 tester.waitFor($('naclModule'));
55 tester.run();
56 //]]>
57 </script>
58 </body>
59 </html>