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

Side by Side Diff: tests/environment_variables/nacl.scons

Issue 7242011: Get rid of assumptions about ".nexe" extension. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: '' Created 9 years, 6 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
« no previous file with comments | « tests/egyptian_cotton/nacl.scons ('k') | tests/fake_browser/nacl.scons » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # -*- python -*- 1 # -*- python -*-
2 # Copyright 2010 The Native Client Authors. All rights reserved. 2 # Copyright 2010 The Native Client Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can 3 # Use of this source code is governed by a BSD-style license that can
4 # be found in the LICENSE file. 4 # be found in the LICENSE file.
5 5
6 Import('env') 6 Import('env')
7 7
8 env.ComponentProgram('env_var_test.nexe', 'env_var_test.c') 8 nexe = env.ComponentProgram('env_var_test', 'env_var_test.c')
9 9
10 nodes = [] 10 nodes = []
11 11
12 nodes.append(env.CommandSelLdrTestNacl( 12 nodes.append(env.CommandSelLdrTestNacl(
13 'empty_env_var_test.out', 13 'empty_env_var_test.out',
14 command=[env.File('env_var_test.nexe')], 14 nexe,
15 stdout_golden=env.File('empty_env.stdout'), 15 stdout_golden=env.File('empty_env.stdout'),
16 osenv='LANG=This_variable_should_not_get_passed_through_by_default')) 16 osenv='LANG=This_variable_should_not_get_passed_through_by_default'))
17 17
18 # Note that Scons has trouble with arguments containing spaces so we 18 # Note that Scons has trouble with arguments containing spaces so we
19 # avoid example values with spaces. 19 # avoid example values with spaces.
20 example_env_args = [ 20 example_env_args = [
21 '-E', 'FOO=contents_of_foo', 21 '-E', 'FOO=contents_of_foo',
22 '-E', 'ANOTHER_VAR=another_environment_variable', 22 '-E', 'ANOTHER_VAR=another_environment_variable',
23 # For simplicity, sel_ldr does not interpret the strings 23 # For simplicity, sel_ldr does not interpret the strings
24 # passed via "-E", so it allows duplicate keys, as well as 24 # passed via "-E", so it allows duplicate keys, as well as
25 # strings not of the form "KEY=VALUE". This is in line with 25 # strings not of the form "KEY=VALUE". This is in line with
26 # how Unix's execve() behaves. We demonstrate this here, but 26 # how Unix's execve() behaves. We demonstrate this here, but
27 # we could change sel_ldr in the future to remove duplicates 27 # we could change sel_ldr in the future to remove duplicates
28 # or require "KEY=VALUE" strings. 28 # or require "KEY=VALUE" strings.
29 '-E', 'DUP=duplicated_key_1', 29 '-E', 'DUP=duplicated_key_1',
30 '-E', 'DUP=duplicated_key_2', 30 '-E', 'DUP=duplicated_key_2',
31 '-E', 'Technically_we_do_not_need_an_equals_sign_here'] 31 '-E', 'Technically_we_do_not_need_an_equals_sign_here']
32 nodes.append(env.CommandSelLdrTestNacl( 32 nodes.append(env.CommandSelLdrTestNacl(
33 'nonempty_env_var_test.out', 33 'nonempty_env_var_test.out',
34 command=[env.File('env_var_test.nexe')], 34 nexe,
35 sel_ldr_flags=example_env_args, 35 sel_ldr_flags=example_env_args,
36 stdout_golden=env.File('nonempty_env.stdout'), 36 stdout_golden=env.File('nonempty_env.stdout'),
37 osenv='LANG=This_variable_should_not_get_passed_through_by_default')) 37 osenv='LANG=This_variable_should_not_get_passed_through_by_default'))
38 38
39 if not env.IsRunningUnderValgrind(): 39 if not env.IsRunningUnderValgrind():
40 env.AddNodeToTestSuite(nodes, ['small_tests'], 'run_env_var_test') 40 env.AddNodeToTestSuite(nodes, ['small_tests'], 'run_env_var_test')
OLDNEW
« no previous file with comments | « tests/egyptian_cotton/nacl.scons ('k') | tests/fake_browser/nacl.scons » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698