OLD | NEW |
1 #! -*- python -*- | 1 #! -*- python -*- |
2 # | 2 # |
3 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 3 # Copyright (c) 2011 The Native Client Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 """Build file for running scripts in the build_tools directory | 7 """Build file for running scripts in the build_tools directory |
8 | 8 |
9 Adapted from scons documentation: http://www.scons.org/wiki/UnitTests | 9 Adapted from scons documentation: http://www.scons.org/wiki/UnitTests |
10 and from ../project_templates/test.scons | 10 and from ../project_templates/test.scons |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 kwargs: See named parameters to CreatePythonUnitTest | 94 kwargs: See named parameters to CreatePythonUnitTest |
95 | 95 |
96 returns: | 96 returns: |
97 test node for this newly created test''' | 97 test node for this newly created test''' |
98 test_node = env.CreatePythonUnitTest(file, **kwargs) | 98 test_node = env.CreatePythonUnitTest(file, **kwargs) |
99 env.AddNodeToTestSuite(test_node, ['bot'], command, size) | 99 env.AddNodeToTestSuite(test_node, ['bot'], command, size) |
100 return test_node | 100 return test_node |
101 | 101 |
102 AddPythonUnitTest('run_build_utils_test', 'tests/build_utils_test.py') | 102 AddPythonUnitTest('run_build_utils_test', 'tests/build_utils_test.py') |
103 AddPythonUnitTest('run_tar_archive_test', 'tests/tar_archive_test.py') | 103 AddPythonUnitTest('run_tar_archive_test', 'tests/tar_archive_test.py') |
104 AddPythonUnitTest('run_update_manifest_test', 'tests/update_manifest_test.py') | 104 AddPythonUnitTest('run_update_manifest_test', |
| 105 'tests/update_manifest_test.py', size='medium') |
105 AddPythonUnitTest('run_sdk_update_test', 'tests/sdk_update_test.py') | 106 AddPythonUnitTest('run_sdk_update_test', 'tests/sdk_update_test.py') |
106 AddPythonUnitTest('run_set_nacl_env_test', 'tests/set_nacl_env_test.py', | 107 AddPythonUnitTest('run_set_nacl_env_test', 'tests/set_nacl_env_test.py', |
107 dependencies=[env.GetToolchainNode()]) | 108 dependencies=[env.GetToolchainNode()]) |
108 AddPythonUnitTest('run_installer_contents_test', | 109 AddPythonUnitTest('run_installer_contents_test', |
109 'tests/installer_contents_test.py') | 110 'tests/installer_contents_test.py') |
110 AddPythonUnitTest('run_nacl_utils_test', 'nacl_sdk_scons/nacl_utils_test.py') | 111 AddPythonUnitTest('run_nacl_utils_test', 'nacl_sdk_scons/nacl_utils_test.py') |
111 AddPythonUnitTest('run_path_set_test', 'tests/path_set_test.py') | 112 AddPythonUnitTest('run_path_set_test', 'tests/path_set_test.py') |
112 AddPythonUnitTest('run_apply_patch_test', 'tests/apply_patch_test.py') | 113 AddPythonUnitTest('run_apply_patch_test', 'tests/apply_patch_test.py') |
113 AddPythonUnitTest('run_nmf_test', | 114 AddPythonUnitTest('run_nmf_test', |
114 'nacl_sdk_scons/nmf_test.py', | 115 'nacl_sdk_scons/nmf_test.py', |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
279 for dir in env['NACL_TOOLCHAIN_ROOTS'].values(): | 280 for dir in env['NACL_TOOLCHAIN_ROOTS'].values(): |
280 all_tools += [os.path.join(dir, tool) for tool in tools] | 281 all_tools += [os.path.join(dir, tool) for tool in tools] |
281 | 282 |
282 nacl_tools_cmd = env.Command(all_tools, | 283 nacl_tools_cmd = env.Command(all_tools, |
283 ['make_nacl_tools.py', | 284 ['make_nacl_tools.py', |
284 os.path.join(env['ROOT_DIR'], 'DEPS')], | 285 os.path.join(env['ROOT_DIR'], 'DEPS')], |
285 build_nacl_tools) | 286 build_nacl_tools) |
286 env.Depends(nacl_tools_cmd, env.GetHeadersNode()) | 287 env.Depends(nacl_tools_cmd, env.GetHeadersNode()) |
287 env.Depends(env.GetToolchainNode(), nacl_tools_cmd) | 288 env.Depends(env.GetToolchainNode(), nacl_tools_cmd) |
288 env.AddCleanAction([], build_nacl_tools, ['toolchain', 'bot'], nacl_tools_cmd) | 289 env.AddCleanAction([], build_nacl_tools, ['toolchain', 'bot'], nacl_tools_cmd) |
OLD | NEW |