OLD | NEW |
1 # Copyright 2012 the V8 project authors. All rights reserved. | 1 # Copyright 2012 the V8 project authors. All rights reserved. |
2 # Redistribution and use in source and binary forms, with or without | 2 # Redistribution and use in source and binary forms, with or without |
3 # modification, are permitted provided that the following conditions are | 3 # modification, are permitted provided that the following conditions are |
4 # met: | 4 # met: |
5 # | 5 # |
6 # * Redistributions of source code must retain the above copyright | 6 # * Redistributions of source code must retain the above copyright |
7 # notice, this list of conditions and the following disclaimer. | 7 # notice, this list of conditions and the following disclaimer. |
8 # * Redistributions in binary form must reproduce the above | 8 # * Redistributions in binary form must reproduce the above |
9 # copyright notice, this list of conditions and the following | 9 # copyright notice, this list of conditions and the following |
10 # disclaimer in the documentation and/or other materials provided | 10 # disclaimer in the documentation and/or other materials provided |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
219 """ | 219 """ |
220 filtered = [] | 220 filtered = [] |
221 globs = [] | 221 globs = [] |
222 exact_matches = [] | 222 exact_matches = [] |
223 for a in args: | 223 for a in args: |
224 argpath = a.split('/') | 224 argpath = a.split('/') |
225 if argpath[0] != self.name: | 225 if argpath[0] != self.name: |
226 continue | 226 continue |
227 if len(argpath) == 1 or (len(argpath) == 2 and argpath[1] == '*'): | 227 if len(argpath) == 1 or (len(argpath) == 2 and argpath[1] == '*'): |
228 return # Don't filter, run all tests in this suite. | 228 return # Don't filter, run all tests in this suite. |
229 path = os.path.sep.join(argpath[1:]) | 229 path = '/'.join(argpath[1:]) |
230 if path[-1] == '*': | 230 if path[-1] == '*': |
231 path = path[:-1] | 231 path = path[:-1] |
232 globs.append(path) | 232 globs.append(path) |
233 else: | 233 else: |
234 exact_matches.append(path) | 234 exact_matches.append(path) |
235 for t in self.tests: | 235 for t in self.tests: |
236 for a in globs: | 236 for a in globs: |
237 if t.path.startswith(a): | 237 if t.path.startswith(a): |
238 filtered.append(t) | 238 filtered.append(t) |
239 break | 239 break |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 return (testcase.flags + ["--gtest_filter=" + testcase.path] + | 324 return (testcase.flags + ["--gtest_filter=" + testcase.path] + |
325 ["--gtest_random_seed=%s" % context.random_seed] + | 325 ["--gtest_random_seed=%s" % context.random_seed] + |
326 ["--gtest_print_time=0"] + | 326 ["--gtest_print_time=0"] + |
327 context.mode_flags) | 327 context.mode_flags) |
328 | 328 |
329 def _VariantGeneratorFactory(self): | 329 def _VariantGeneratorFactory(self): |
330 return StandardVariantGenerator | 330 return StandardVariantGenerator |
331 | 331 |
332 def shell(self): | 332 def shell(self): |
333 return self.name | 333 return self.name |
OLD | NEW |