Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2015 The Chromium Authors. All rights reserved. | 2 # Copyright 2015 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 """MB - the Meta-Build wrapper around GYP and GN | 6 """MB - the Meta-Build wrapper around GYP and GN |
| 7 | 7 |
| 8 MB is a wrapper script for GYP and GN that can be used to generate build files | 8 MB is a wrapper script for GYP and GN that can be used to generate build files |
| 9 for sets of canned configurations and analyze them. | 9 for sets of canned configurations and analyze them. |
| 10 """ | 10 """ |
| (...skipping 1048 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1059 isolate_map = self.ReadIsolateMap() | 1059 isolate_map = self.ReadIsolateMap() |
| 1060 | 1060 |
| 1061 android = 'target_os="android"' in vals['gn_args'] | 1061 android = 'target_os="android"' in vals['gn_args'] |
| 1062 ozone = 'use_ozone=true' in vals['gn_args'] | 1062 ozone = 'use_ozone=true' in vals['gn_args'] |
| 1063 chromeos = 'target_os="chromeos"' in vals['gn_args'] | 1063 chromeos = 'target_os="chromeos"' in vals['gn_args'] |
| 1064 | 1064 |
| 1065 # This should be true if tests with type='windowed_test_launcher' are | 1065 # This should be true if tests with type='windowed_test_launcher' are |
| 1066 # expected to run using xvfb. For example, Linux Desktop, X11 CrOS and | 1066 # expected to run using xvfb. For example, Linux Desktop, X11 CrOS and |
| 1067 # Ozone CrOS builds. | 1067 # Ozone CrOS builds. |
| 1068 use_xvfb = (self.platform == 'linux2' and | 1068 use_xvfb = (self.platform == 'linux2' and |
| 1069 not android and | 1069 not android and ozone or (ozone and chromeos)) |
|
fwang
2017/03/20 15:10:35
I think ((not ozone) or (ozone and chromeos)) can
kylechar
2017/03/20 17:03:31
Yep, like this:
use_xvfb = (self.platform == 'lin
Dirk Pranke
2017/03/20 17:22:50
So there's no non-X11 configuration we're testing
kylechar
2017/03/20 17:30:42
This particular change only affects 'Ozone Linux'
Dirk Pranke
2017/03/20 17:36:57
I guess we were already assuming CrOS+Ozone==X11.
fwang
2017/03/21 06:54:29
What about this:
"... For example, Linux Desktop,
msisov
2017/03/21 07:18:16
Done.
| |
| 1070 ((not ozone) or (ozone and chromeos))) | |
| 1071 | 1070 |
| 1072 asan = 'is_asan=true' in vals['gn_args'] | 1071 asan = 'is_asan=true' in vals['gn_args'] |
| 1073 msan = 'is_msan=true' in vals['gn_args'] | 1072 msan = 'is_msan=true' in vals['gn_args'] |
| 1074 tsan = 'is_tsan=true' in vals['gn_args'] | 1073 tsan = 'is_tsan=true' in vals['gn_args'] |
| 1075 | 1074 |
| 1076 test_type = isolate_map[target]['type'] | 1075 test_type = isolate_map[target]['type'] |
| 1077 | 1076 |
| 1078 executable = isolate_map[target].get('executable', target) | 1077 executable = isolate_map[target].get('executable', target) |
| 1079 executable_suffix = '.exe' if self.platform == 'win32' else '' | 1078 executable_suffix = '.exe' if self.platform == 'win32' else '' |
| 1080 | 1079 |
| (...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1560 # Then check to see if the arg contains any metacharacters other than | 1559 # Then check to see if the arg contains any metacharacters other than |
| 1561 # double quotes; if it does, quote everything (including the double | 1560 # double quotes; if it does, quote everything (including the double |
| 1562 # quotes) for safety. | 1561 # quotes) for safety. |
| 1563 if any(a in UNSAFE_FOR_CMD for a in arg): | 1562 if any(a in UNSAFE_FOR_CMD for a in arg): |
| 1564 arg = ''.join('^' + a if a in ALL_META_CHARS else a for a in arg) | 1563 arg = ''.join('^' + a if a in ALL_META_CHARS else a for a in arg) |
| 1565 return arg | 1564 return arg |
| 1566 | 1565 |
| 1567 | 1566 |
| 1568 if __name__ == '__main__': | 1567 if __name__ == '__main__': |
| 1569 sys.exit(main(sys.argv[1:])) | 1568 sys.exit(main(sys.argv[1:])) |
| OLD | NEW |