OLD | NEW |
---|---|
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright 2014 The Chromium Authors. All rights reserved. | 2 # Copyright 2014 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 """Central list of tests to run (as appropriate for a given config). Add tests | 6 """Central list of tests to run (as appropriate for a given config). Add tests |
7 to run by modifying this file. | 7 to run by modifying this file. |
8 | 8 |
9 Note that this file is both imported (by mojob.py) and run directly (via a | 9 Note that this file is both imported (by mojob.py) and run directly (via a |
10 recipe).""" | 10 recipe).""" |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
73 # TODO(vtl): Currently, we only know how to run tests for Android, Linux, or | 73 # TODO(vtl): Currently, we only know how to run tests for Android, Linux, or |
74 # Windows. | 74 # Windows. |
75 if target_os not in (Config.OS_ANDROID, Config.OS_LINUX, Config.OS_WINDOWS, | 75 if target_os not in (Config.OS_ANDROID, Config.OS_LINUX, Config.OS_WINDOWS, |
76 Config.OS_IOS): | 76 Config.OS_IOS): |
77 return test_list | 77 return test_list |
78 | 78 |
79 # Tests run by default ------------------------------------------------------- | 79 # Tests run by default ------------------------------------------------------- |
80 | 80 |
81 # C++ unit tests: | 81 # C++ unit tests: |
82 if ShouldRunTest(Config.TEST_TYPE_DEFAULT, Config.TEST_TYPE_UNIT): | 82 if ShouldRunTest(Config.TEST_TYPE_DEFAULT, Config.TEST_TYPE_UNIT): |
83 # Base Unittests | |
84 AddEntry("Base Unit Tests", | |
85 [os.path.join(build_dir, "base_unittests")] + verbose_flags) | |
viettrungluu
2015/11/16 19:51:03
Please just add this to the mojo/tools/data/unitte
Sean Klein
2015/11/16 21:38:57
Done.
| |
86 | |
83 AddXvfbEntry("Unit tests", | 87 AddXvfbEntry("Unit tests", |
84 [os.path.join("mojo", "tools", "test_runner.py"), | 88 [os.path.join("mojo", "tools", "test_runner.py"), |
85 os.path.join("mojo", "tools", "data", "unittests"), | 89 os.path.join("mojo", "tools", "data", "unittests"), |
86 build_dir] + verbose_flags) | 90 build_dir] + verbose_flags) |
87 # NaCl tests (Linux only): | 91 # NaCl tests (Linux only): |
88 if (target_os == Config.OS_LINUX and | 92 if (target_os == Config.OS_LINUX and |
89 config.sanitizer != Config.SANITIZER_ASAN): | 93 config.sanitizer != Config.SANITIZER_ASAN): |
90 AddEntry("SFI NaCl tests", | 94 AddEntry("SFI NaCl tests", |
91 [os.path.join(build_dir, "monacl_shell"), | 95 [os.path.join(build_dir, "monacl_shell"), |
92 os.path.join(build_dir, "irt_" + config.target_cpu, | 96 os.path.join(build_dir, "irt_" + config.target_cpu, |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
293 config = Config(**json.load(args.config_file)) | 297 config = Config(**json.load(args.config_file)) |
294 test_list = GetTestList(config) | 298 test_list = GetTestList(config) |
295 json.dump(test_list, args.test_list_file, indent=2) | 299 json.dump(test_list, args.test_list_file, indent=2) |
296 args.test_list_file.write("\n") | 300 args.test_list_file.write("\n") |
297 | 301 |
298 return 0 | 302 return 0 |
299 | 303 |
300 | 304 |
301 if __name__ == "__main__": | 305 if __name__ == "__main__": |
302 sys.exit(main()) | 306 sys.exit(main()) |
OLD | NEW |