Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 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 import os | 6 import os |
| 7 import sys | 7 import sys |
| 8 import unittest | 8 import unittest |
| 9 import glob | |
| 10 | 9 |
| 11 from dart_generator import DartGenerator | |
| 12 from compiler import GenerateSchema | 10 from compiler import GenerateSchema |
| 13 | 11 |
| 14 # If --rebase is passed to this test, this is set to True, indicating the test | 12 # If --rebase is passed to this test, this is set to True, indicating the test |
| 15 # output should be re-generated for each test (rather than running the tests | 13 # output should be re-generated for each test (rather than running the tests |
| 16 # themselves). | 14 # themselves). |
| 17 REBASE_MODE = False | 15 REBASE_MODE = False |
| 18 | 16 |
| 19 # The directory containing the input and expected output files corresponding | 17 # The directory containing the input and expected output files corresponding |
| 20 # to each test name. | 18 # to each test name. |
| 21 TESTS_DIR = 'dart_test' | 19 TESTS_DIR = 'dart_test' |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 55 | 53 |
| 56 def testDictionaries(self): | 54 def testDictionaries(self): |
| 57 self._RunTest('dictionaries') | 55 self._RunTest('dictionaries') |
| 58 | 56 |
| 59 def testEmptyNamespace(self): | 57 def testEmptyNamespace(self): |
| 60 self._RunTest('empty_namespace') | 58 self._RunTest('empty_namespace') |
| 61 | 59 |
| 62 def testEmptyType(self): | 60 def testEmptyType(self): |
| 63 self._RunTest('empty_type') | 61 self._RunTest('empty_type') |
| 64 | 62 |
| 65 def testEvents(self): | 63 def testEnums(self): |
| 66 self._RunTest('enums') | 64 self._RunTest('enums') |
|
benwells
2013/09/10 00:53:01
Could you just delete this test and its associated
dhnishi (use Chromium)
2013/09/10 17:21:37
Done.
| |
| 67 | 65 |
| 68 def testEvents(self): | 66 def testEvents(self): |
| 69 self._RunTest('events') | 67 self._RunTest('events') |
| 70 | 68 |
| 71 def testBasicFunction(self): | 69 def testBasicFunction(self): |
| 72 self._RunTest('functions') | 70 self._RunTest('functions') |
| 73 | 71 |
| 74 def testOpratableType(self): | 72 def testOpratableType(self): |
| 75 self._RunTest('operatable_type') | 73 self._RunTest('operatable_type') |
| 76 | 74 |
| 77 def testTags(self): | 75 def testTags(self): |
| 78 self._RunTest('tags') | 76 self._RunTest('tags') |
| 79 | 77 |
| 80 if __name__ == '__main__': | 78 if __name__ == '__main__': |
| 81 if '--rebase' in sys.argv: | 79 if '--rebase' in sys.argv: |
| 82 print "Running in rebase mode." | 80 print "Running in rebase mode." |
| 83 REBASE_MODE = True | 81 REBASE_MODE = True |
| 84 sys.argv.remove('--rebase') | 82 sys.argv.remove('--rebase') |
| 85 unittest.main() | 83 unittest.main() |
| OLD | NEW |