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

Side by Side Diff: tools/testing/test_configuration.py

Issue 9297032: Refactoring to migrate layout tests over. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Drop the forLayoutTests Created 8 years, 10 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 | « client/tests/client/test_config.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 # Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 # for details. All rights reserved. Use of this source code is governed by a 2 # for details. All rights reserved. Use of this source code is governed by a
3 # BSD-style license that can be found in the LICENSE file. 3 # BSD-style license that can be found in the LICENSE file.
4 4
5 """Common Testconfiguration subclasses used to define a class of tests.""" 5 """Common Testconfiguration subclasses used to define a class of tests."""
6 6
7 import atexit 7 import atexit
8 import fileinput 8 import fileinput
9 import os 9 import os
10 import re 10 import re
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 continue 249 continue
250 tests.append(test_case.BrowserTestCase(self.context, 250 tests.append(test_case.BrowserTestCase(self.context,
251 test_path, 251 test_path,
252 os.path.join(root, f), 252 os.path.join(root, f),
253 self.fatal_static_type_errors, 253 self.fatal_static_type_errors,
254 mode, arch, component)) 254 mode, arch, component))
255 atexit.register(lambda: self._Cleanup(tests)) 255 atexit.register(lambda: self._Cleanup(tests))
256 return tests 256 return tests
257 257
258 def IsTest(self, name): 258 def IsTest(self, name):
259 return name.endswith('_tests.dart') 259 return name.endswith('_tests.dart') or name.endswith('Test.dart')
260 260
261 261
262 class CompilationTestConfiguration(test.TestConfiguration): 262 class CompilationTestConfiguration(test.TestConfiguration):
263 """Configuration that searches specific directories for apps to compile. 263 """Configuration that searches specific directories for apps to compile.
264 264
265 Expects a status file named dartc.status 265 Expects a status file named dartc.status
266 """ 266 """
267 267
268 def __init__(self, context, root): 268 def __init__(self, context, root):
269 super(CompilationTestConfiguration, self).__init__(context, root) 269 super(CompilationTestConfiguration, self).__init__(context, root)
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 317
318 def GetTestStatus(self, sections, defs): 318 def GetTestStatus(self, sections, defs):
319 status = os.path.join(self.root, 'dartc.status') 319 status = os.path.join(self.root, 'dartc.status')
320 if os.path.exists(status): 320 if os.path.exists(status):
321 test.ReadConfigurationInto(status, sections, defs) 321 test.ReadConfigurationInto(status, sections, defs)
322 322
323 def _Cleanup(self, tests): 323 def _Cleanup(self, tests):
324 if not utils.Daemonize(): return 324 if not utils.Daemonize(): return
325 os.execlp('rm', *(['rm', '-rf'] + [t.temp_dir for t in tests])) 325 os.execlp('rm', *(['rm', '-rf'] + [t.temp_dir for t in tests]))
326 raise 326 raise
OLDNEW
« no previous file with comments | « client/tests/client/test_config.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698