OLD | NEW |
(Empty) | |
| 1 # -*- python -*- |
| 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. |
| 5 # |
| 6 # Tests fatal errors that occur after loading. |
| 7 # (See ppapi_browser/bad for fatal errors that occur during loading). |
| 8 # |
| 9 # The tests use ppapi_test_lib. |
| 10 |
| 11 Import('env') |
| 12 |
| 13 env.Prepend(CPPDEFINES=['XP_UNIX']) |
| 14 |
| 15 crash_types = ['via_check_failure', 'via_exit_call', 'in_callback'] |
| 16 published_files = [] |
| 17 |
| 18 for crash_type in crash_types: |
| 19 nexe = 'ppapi_crash_%s_%s' % (crash_type, env.get('TARGET_FULLARCH')) |
| 20 env.Alias('ppapi_crash_%s${PROGSUFFIX}' % crash_type, |
| 21 ['$STAGING_DIR/%s${PROGSUFFIX}' % nexe]) |
| 22 |
| 23 env.ComponentProgram( |
| 24 nexe, |
| 25 ['ppapi_crash_%s.cc' % crash_type], |
| 26 EXTRA_LIBS=['${PPAPI_LIBS}', |
| 27 'ppapi_test_lib', |
| 28 'platform', |
| 29 'pthread', |
| 30 'gio']) |
| 31 |
| 32 # TODO(polina): follow ppapi_browser/bad nacl.scons to publish html only once |
| 33 # and to associate all nexes and nmf files with one target that can be |
| 34 # referenced in tests/nacl.scons. |
| 35 env.Publish(nexe, 'run', |
| 36 ['ppapi_crash.html', |
| 37 'ppapi_crash_%s.nmf' % crash_type ]) |
| 38 |
| 39 published_files.extend(env.ExtractPublishedFiles(nexe)) |
| 40 |
| 41 node = env.PPAPIBrowserTester('ppapi_crash_browser_test.out', |
| 42 url='ppapi_crash.html', |
| 43 files=published_files) |
| 44 |
| 45 env.AddNodeToTestSuite(node, |
| 46 ['chrome_browser_tests'], |
| 47 'run_ppapi_crash_browser_test', |
| 48 is_broken=env.PPAPIBrowserTesterIsBroken()) |
OLD | NEW |