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

Side by Side Diff: ppapi/native_client/tests/breakpad_crash_test/nacl.scons

Issue 10407058: Compile in Breakpad by default on Linux (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Don't add -g by default + rebase Created 7 years, 11 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
1 # -*- python -*- 1 # -*- python -*-
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import os 6 import os
7 7
8 Import('env') 8 Import('env')
9 9
10 if env.Bit('host_windows') or env.Bit('host_mac'): 10 if env.Bit('host_windows') or env.Bit('host_mac'):
11 expected_crash_dumps = 1 11 expected_crash_dumps = 1
12 else: 12 else:
13 # We are also checking that crash dumping does not work 13 # We are also checking that crash dumping does not work
14 # unexpectedly, since that might indicate that Breakpad was enabled 14 # unexpectedly, since that might indicate that Breakpad was enabled
15 # without checking that it works securely. 15 # without checking that it works securely.
16 expected_crash_dumps = 0 16 expected_crash_dumps = 0
17 17
18 platform_args = [] 18 platform_args = []
19 if env.Bit('host_windows') and env.Bit('build_x86_64'): 19 if env.Bit('host_windows') and env.Bit('build_x86_64'):
20 platform_args.append('--win64') 20 platform_args.append('--win64')
21 21
22 def GetNexeByName(name): 22 def GetNexeByName(name):
23 return env.File('${STAGING_DIR}/%s${PROGSUFFIX}' % 23 return env.File('${STAGING_DIR}/%s${PROGSUFFIX}' %
24 env.ProgramNameForNmf(name)) 24 env.ProgramNameForNmf(name))
25 25
26 26
27 # This tests that crashes in Chromium's browser process successfully 27 # This tests that crashes in Chromium's browser process successfully
28 # produce crash dumps via Breakpad. 28 # produce crash dumps via Breakpad.
29 # TODO(mseaborn): Enable this for Linux, too, when Breakpad is 29 node = env.PPAPIBrowserTester(
30 # compiled into Chromium by default. 30 'breakpad_browser_process_crash_test.out',
31 # See http://code.google.com/p/chromium/issues/detail?id=105778 31 python_tester_script=env.File('crash_dump_tester.py'),
32 if env.Bit('host_windows') or env.Bit('host_mac'): 32 browser_flags=['--crash-test'], # Tell the browser process to crash.
33 node = env.PPAPIBrowserTester( 33 url='browser_process_crash.html',
34 'breakpad_browser_process_crash_test.out', 34 nmf_names=[],
35 python_tester_script=env.File('crash_dump_tester.py'), 35 files=[env.File('browser_process_crash.html')],
36 browser_flags=['--crash-test'], # Tell the browser process to crash. 36 args=platform_args + ['--expect_browser_process_crash',
37 url='browser_process_crash.html', 37 '--expected_crash_dumps=1',
38 nmf_names=[], 38 '--expected_process_type=browser'])
39 files=[env.File('browser_process_crash.html')], 39 env.AddNodeToTestSuite(
40 args=platform_args + ['--expect_browser_process_crash', 40 node, ['chrome_browser_tests'], 'run_breakpad_browser_process_crash_test',
41 '--expected_crash_dumps=1', 41 # For some strange reason, this test sometimes fails on the
42 '--expected_process_type=browser']) 42 # second run (for the SRPC PPAPI proxy) on the Windows 32-bit
43 env.AddNodeToTestSuite( 43 # and 64-bit buildbots. The failure modes are that the browser
44 node, ['chrome_browser_tests'], 'run_breakpad_browser_process_crash_test', 44 # process hangs, or that a .dmp file is produced with no .txt
45 # For some strange reason, this test sometimes fails on the 45 # file. Maybe there is a problem with the command line getting
46 # second run (for the SRPC PPAPI proxy) on the Windows 32-bit 46 # too long?
47 # and 64-bit buildbots. The failure modes are that the browser 47 # TODO(mseaborn): Remove this when the "--enable-nacl-srpc-proxy"
48 # process hangs, or that a .dmp file is produced with no .txt 48 # option is removed, or investigate and fix.
49 # file. Maybe there is a problem with the command line getting 49 is_broken=(env.PPAPIBrowserTesterIsBroken() or
50 # too long? 50 env.Bit('running_on_valgrind') or
51 # TODO(mseaborn): Remove this when the "--enable-nacl-srpc-proxy" 51 (env.Bit('host_windows') and
52 # option is removed, or investigate and fix. 52 '--enable-nacl-srpc-proxy' in
53 is_broken=(env.PPAPIBrowserTesterIsBroken() or 53 os.environ.get('NACL_BROWSER_FLAGS', ''))))
54 env.Bit('running_on_valgrind') or
55 (env.Bit('host_windows') and
56 '--enable-nacl-srpc-proxy' in
57 os.environ.get('NACL_BROWSER_FLAGS', ''))))
58 54
59 # This crash in trusted code should produce a crash dump. 55 # This crash in trusted code should produce a crash dump.
60 crash_test_url = 'trusted_crash_in_startup.html' 56 crash_test_url = 'trusted_crash_in_startup.html'
61 if env.Bit('pnacl_generate_pexe'): 57 if env.Bit('pnacl_generate_pexe'):
62 crash_test_url += '?is_pnacl=true' 58 crash_test_url += '?is_pnacl=true'
63 node = env.PPAPIBrowserTester( 59 node = env.PPAPIBrowserTester(
64 'breakpad_trusted_crash_in_startup_test.out', 60 'breakpad_trusted_crash_in_startup_test.out',
65 python_tester_script=env.File('crash_dump_tester.py'), 61 python_tester_script=env.File('crash_dump_tester.py'),
66 url=crash_test_url, 62 url=crash_test_url,
67 nmf_names=['crash_test'], 63 nmf_names=['crash_test'],
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 python_tester_script=env.File('crash_dump_tester.py'), 95 python_tester_script=env.File('crash_dump_tester.py'),
100 url='untrusted_crash.html', 96 url='untrusted_crash.html',
101 nmf_names=['crash_test'], 97 nmf_names=['crash_test'],
102 files=[GetNexeByName('crash_test'), 98 files=[GetNexeByName('crash_test'),
103 env.File('untrusted_crash.html')], 99 env.File('untrusted_crash.html')],
104 args=platform_args + ['--expected_crash_dumps=0']) 100 args=platform_args + ['--expected_crash_dumps=0'])
105 env.AddNodeToTestSuite( 101 env.AddNodeToTestSuite(
106 node, ['chrome_browser_tests'], 'run_breakpad_untrusted_crash_test', 102 node, ['chrome_browser_tests'], 'run_breakpad_untrusted_crash_test',
107 is_broken=env.PPAPIBrowserTesterIsBroken() or 103 is_broken=env.PPAPIBrowserTesterIsBroken() or
108 env.Bit('running_on_valgrind')) 104 env.Bit('running_on_valgrind'))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698