2 Copyright (c) 2011 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.
6 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
7 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
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 Fault-Injection Test</title>
17 <h1>Native Client Fault-Injection Test</h1>
18 <script type="text/javascript">
20 var tester = new Tester($('body'));
21 var gotExpected = false;
22 var args = getTestArguments({'expected_error' :
23 'THIS TEST CANNOT RUN STANDALONE -- run using scons instead'});
24 var errorListener = function(e) {
25 var target_element = e.target;
26 if (target_element.id != 'naclModule') {
27 alert('not nacl module');
30 if (e.type == 'error') {
31 if ($('naclModule').lastError == args.expected_error) {
37 function setupTests(tester) {
38 tester.addAsyncTest('dummy', function(status) {
39 status.assert(gotExpected);
45 tester.loadErrorsAreOK();
47 tester.waitFor($('naclModule'));
51 $('body').addEventListener('error', errorListener, true);
55 <embed id="naclModule"
58 src="fault_pm_nameservice_test.nmf"
61 style="background-color:gray"
62 type="application/x-nacl" />
64 <script type="text/javascript">