Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 #library("test_suite"); | 5 #library("test_suite"); |
| 6 | 6 |
| 7 #import("dart:io"); | 7 #import("dart:io"); |
| 8 #import("status_file_parser.dart"); | 8 #import("status_file_parser.dart"); |
| 9 #import("test_runner.dart"); | 9 #import("test_runner.dart"); |
| 10 #import("multitest.dart"); | 10 #import("multitest.dart"); |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 247 start = filename.lastIndexOf('/'); | 247 start = filename.lastIndexOf('/'); |
| 248 int middle = filename.lastIndexOf('_'); | 248 int middle = filename.lastIndexOf('_'); |
| 249 testName = filename.substring(start + 1, middle) + '/' + | 249 testName = filename.substring(start + 1, middle) + '/' + |
| 250 filename.substring(middle + 1, filename.length - 5); | 250 filename.substring(middle + 1, filename.length - 5); |
| 251 } else { | 251 } else { |
| 252 // This case is hit by the dartc client compilation | 252 // This case is hit by the dartc client compilation |
| 253 // tests. These tests are pretty broken compared to the | 253 // tests. These tests are pretty broken compared to the |
| 254 // rest. They use the .dart suffix in the status files. They | 254 // rest. They use the .dart suffix in the status files. They |
| 255 // find tests in weird ways (testing that they contain "#"). | 255 // find tests in weird ways (testing that they contain "#"). |
| 256 // They need to be redone. | 256 // They need to be redone. |
| 257 // directoryPath may start with '../'. | |
| 258 // TODO(1058): This does not work on Windows. | 257 // TODO(1058): This does not work on Windows. |
|
Mads Ager (google)
2012/02/01 12:57:46
Is this TODO obsolete?
| |
| 259 String sanitizedDirectoryPath = (directoryPath.startsWith('../')) ? | 258 start = filename.indexOf(directoryPath); |
| 260 directoryPath.substring(3) : directoryPath; | 259 if (start != -1) { |
| 261 start = filename.indexOf(sanitizedDirectoryPath); | 260 testName = filename.substring(start + directoryPath.length + 1); |
| 262 testName = filename.substring(start + sanitizedDirectoryPath.length + 1, | 261 } else { |
| 263 filename.length); | 262 testName = filename; |
| 263 } | |
| 264 | |
| 264 if (configuration['component'] != 'dartc') { | 265 if (configuration['component'] != 'dartc') { |
| 265 if (testName.endsWith('.dart')) { | 266 if (testName.endsWith('.dart')) { |
| 266 testName = testName.substring(0, testName.length - 5); | 267 testName = testName.substring(0, testName.length - 5); |
| 267 } | 268 } |
| 268 } | 269 } |
| 269 } | 270 } |
| 270 Set<String> expectations = testExpectations.expectations(testName); | 271 Set<String> expectations = testExpectations.expectations(testName); |
| 271 if (configuration['report']) { | 272 if (configuration['report']) { |
| 272 // Tests with multiple VMOptions are counted more than once. | 273 // Tests with multiple VMOptions are counted more than once. |
| 273 for (var dummy in optionsFromFile["vmOptions"]) { | 274 for (var dummy in optionsFromFile["vmOptions"]) { |
| (...skipping 782 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1056 * $noCrash tests are expected to be flaky but not crash | 1057 * $noCrash tests are expected to be flaky but not crash |
| 1057 * $pass tests are expected to pass | 1058 * $pass tests are expected to pass |
| 1058 * $failOk tests are expected to fail that we won't fix | 1059 * $failOk tests are expected to fail that we won't fix |
| 1059 * $fail tests are expected to fail that we should fix | 1060 * $fail tests are expected to fail that we should fix |
| 1060 * $crash tests are expected to crash that we should fix | 1061 * $crash tests are expected to crash that we should fix |
| 1061 * $timeout tests are allowed to timeout | 1062 * $timeout tests are allowed to timeout |
| 1062 """; | 1063 """; |
| 1063 print(report); | 1064 print(report); |
| 1064 } | 1065 } |
| 1065 } | 1066 } |
| OLD | NEW |