Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 #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 970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 981 } | 981 } |
| 982 | 982 |
| 983 static String buildDir(Map configuration) { | 983 static String buildDir(Map configuration) { |
| 984 var buildDir = outputDir(configuration); | 984 var buildDir = outputDir(configuration); |
| 985 buildDir += (configuration['mode'] == 'debug') ? 'Debug_' : 'Release_'; | 985 buildDir += (configuration['mode'] == 'debug') ? 'Debug_' : 'Release_'; |
| 986 buildDir += configuration['arch']; | 986 buildDir += configuration['arch']; |
| 987 return buildDir; | 987 return buildDir; |
| 988 } | 988 } |
| 989 | 989 |
| 990 static String dartDir() { | 990 static String dartDir() { |
| 991 Directory dart; | 991 Directory dart; |
|
antonm
2012/01/31 16:21:38
do you need this line at all?
Bill Hesse
2012/02/01 11:48:34
no.
On 2012/01/31 16:21:38, antonm wrote:
| |
| 992 if (new File('tools/testing/dart/test_suite.dart').existsSync()) { | 992 String scriptPath = new Options().script.replaceAll('\\', '/'); |
| 993 return new File('.').fullPathSync().replaceAll('\\', '/'); | 993 String toolsDir = scriptPath.substring(0, scriptPath.lastIndexOf('/')); |
| 994 } else if (new File('../tools/testing/dart/test_suite.dart').existsSync()) { | 994 return new File('$toolsDir/..').fullPathSync().replaceAll('\\', '/'); |
| 995 return new File('..').fullPathSync().replaceAll('\\', '/'); | |
| 996 } else { | |
| 997 print('Run test.dart from the dart directory or' + | |
| 998 ' an immediate subdirectory only.'); | |
| 999 Expect.fail('Could not find top level dart directory.'); | |
| 1000 } | |
| 1001 } | 995 } |
| 1002 | 996 |
| 1003 static List<String> standardOptions(Map configuration) { | 997 static List<String> standardOptions(Map configuration) { |
| 1004 List args = ["--ignore-unrecognized-flags"]; | 998 List args = ["--ignore-unrecognized-flags"]; |
| 1005 if (configuration["checked"]) { | 999 if (configuration["checked"]) { |
| 1006 args.add('--enable_asserts'); | 1000 args.add('--enable_asserts'); |
| 1007 args.add("--enable_type_checks"); | 1001 args.add("--enable_type_checks"); |
| 1008 } | 1002 } |
| 1009 if (configuration["component"] == "leg") { | 1003 if (configuration["component"] == "leg") { |
| 1010 args.add("--enable_leg"); | 1004 args.add("--enable_leg"); |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1063 * $noCrash tests are expected to be flaky but not crash | 1057 * $noCrash tests are expected to be flaky but not crash |
| 1064 * $pass tests are expected to pass | 1058 * $pass tests are expected to pass |
| 1065 * $failOk tests are expected to fail that we won't fix | 1059 * $failOk tests are expected to fail that we won't fix |
| 1066 * $fail tests are expected to fail that we should fix | 1060 * $fail tests are expected to fail that we should fix |
| 1067 * $crash tests are expected to crash that we should fix | 1061 * $crash tests are expected to crash that we should fix |
| 1068 * $timeout tests are allowed to timeout | 1062 * $timeout tests are allowed to timeout |
| 1069 """; | 1063 """; |
| 1070 print(report); | 1064 print(report); |
| 1071 } | 1065 } |
| 1072 } | 1066 } |
| OLD | NEW |