| OLD | NEW |
| 1 # Copyright (C) 2010 Google Inc. All rights reserved. | 1 # Copyright (C) 2010 Google Inc. All rights reserved. |
| 2 # | 2 # |
| 3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
| 4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
| 5 # met: | 5 # met: |
| 6 # | 6 # |
| 7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
| 8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
| 9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
| 10 # copyright notice, this list of conditions and the following disclaimer | 10 # copyright notice, this list of conditions and the following disclaimer |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 def __contains__(self, item): | 96 def __contains__(self, item): |
| 97 return item in self.tests | 97 return item in self.tests |
| 98 | 98 |
| 99 def __getitem__(self, item): | 99 def __getitem__(self, item): |
| 100 return self.tests[item] | 100 return self.tests[item] |
| 101 | 101 |
| 102 # | 102 # |
| 103 # These numbers may need to be updated whenever we add or delete tests. This inc
ludes virtual tests. | 103 # These numbers may need to be updated whenever we add or delete tests. This inc
ludes virtual tests. |
| 104 # | 104 # |
| 105 TOTAL_TESTS = 106 | 105 TOTAL_TESTS = 106 |
| 106 TOTAL_SKIPS = 22 | 106 TOTAL_WONTFIX = 3 |
| 107 TOTAL_SKIPS = 22 + TOTAL_WONTFIX |
| 107 TOTAL_CRASHES = 76 | 108 TOTAL_CRASHES = 76 |
| 109 |
| 108 UNEXPECTED_PASSES = 1 | 110 UNEXPECTED_PASSES = 1 |
| 109 UNEXPECTED_FAILURES = 26 | 111 UNEXPECTED_FAILURES = 26 |
| 110 | 112 |
| 111 | 113 |
| 112 def unit_test_list(): | 114 def unit_test_list(): |
| 113 tests = TestList() | 115 tests = TestList() |
| 114 tests.add('failures/expected/crash.html', crash=True) | 116 tests.add('failures/expected/crash.html', crash=True) |
| 115 tests.add('failures/expected/exception.html', exception=True) | 117 tests.add('failures/expected/exception.html', exception=True) |
| 116 tests.add('failures/expected/device_failure.html', device_failure=True) | 118 tests.add('failures/expected/device_failure.html', device_failure=True) |
| 117 tests.add('failures/expected/timeout.html', timeout=True) | 119 tests.add('failures/expected/timeout.html', timeout=True) |
| (...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 291 Bug(test) failures/expected/timeout.html [ Timeout ] | 293 Bug(test) failures/expected/timeout.html [ Timeout ] |
| 292 Bug(test) failures/expected/keyboard.html [ Crash ] | 294 Bug(test) failures/expected/keyboard.html [ Crash ] |
| 293 Bug(test) failures/expected/exception.html [ Crash ] | 295 Bug(test) failures/expected/exception.html [ Crash ] |
| 294 Bug(test) failures/expected/device_failure.html [ Crash ] | 296 Bug(test) failures/expected/device_failure.html [ Crash ] |
| 295 Bug(test) failures/expected/leak.html [ Leak ] | 297 Bug(test) failures/expected/leak.html [ Leak ] |
| 296 Bug(test) failures/unexpected/pass.html [ Failure ] | 298 Bug(test) failures/unexpected/pass.html [ Failure ] |
| 297 Bug(test) passes/skipped/skip.html [ Skip ] | 299 Bug(test) passes/skipped/skip.html [ Skip ] |
| 298 Bug(test) passes/text.html [ Pass ] | 300 Bug(test) passes/text.html [ Pass ] |
| 299 """) | 301 """) |
| 300 | 302 |
| 303 if not filesystem.exists(LAYOUT_TEST_DIR + '/NeverFixTests'): |
| 304 filesystem.write_text_file(LAYOUT_TEST_DIR + '/NeverFixTests', """ |
| 305 Bug(test) failures/expected/keyboard.html [ WontFix ] |
| 306 Bug(test) failures/expected/exception.html [ WontFix ] |
| 307 Bug(test) failures/expected/device_failure.html [ WontFix ] |
| 308 """) |
| 309 |
| 301 filesystem.maybe_make_directory(LAYOUT_TEST_DIR + '/reftests/foo') | 310 filesystem.maybe_make_directory(LAYOUT_TEST_DIR + '/reftests/foo') |
| 302 filesystem.write_text_file(LAYOUT_TEST_DIR + '/reftests/foo/reftest.list', "
"" | 311 filesystem.write_text_file(LAYOUT_TEST_DIR + '/reftests/foo/reftest.list', "
"" |
| 303 == test.html test-ref.html | 312 == test.html test-ref.html |
| 304 | 313 |
| 305 == multiple-match-success.html mismatching-ref.html | 314 == multiple-match-success.html mismatching-ref.html |
| 306 == multiple-match-success.html matching-ref.html | 315 == multiple-match-success.html matching-ref.html |
| 307 == multiple-match-failure.html mismatching-ref.html | 316 == multiple-match-failure.html mismatching-ref.html |
| 308 == multiple-match-failure.html second-mismatching-ref.html | 317 == multiple-match-failure.html second-mismatching-ref.html |
| 309 != multiple-mismatch-success.html mismatching-ref.html | 318 != multiple-mismatch-success.html mismatching-ref.html |
| 310 != multiple-mismatch-success.html second-mismatching-ref.html | 319 != multiple-mismatch-success.html second-mismatching-ref.html |
| (...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 624 else: | 633 else: |
| 625 image = test.actual_image | 634 image = test.actual_image |
| 626 return DriverOutput(actual_text, image, test.actual_checksum, audio, | 635 return DriverOutput(actual_text, image, test.actual_checksum, audio, |
| 627 crash=(crash or web_process_crash), crashed_process_
name=crashed_process_name, | 636 crash=(crash or web_process_crash), crashed_process_
name=crashed_process_name, |
| 628 crashed_pid=crashed_pid, crash_log=crash_log, | 637 crashed_pid=crashed_pid, crash_log=crash_log, |
| 629 test_time=time.time() - start_time, timeout=test.tim
eout, error=test.error, pid=self.pid, | 638 test_time=time.time() - start_time, timeout=test.tim
eout, error=test.error, pid=self.pid, |
| 630 leak=test.leak) | 639 leak=test.leak) |
| 631 | 640 |
| 632 def stop(self): | 641 def stop(self): |
| 633 self.started = False | 642 self.started = False |
| OLD | NEW |