 Chromium Code Reviews
 Chromium Code Reviews Issue 11280085:
  Add --checked or --minified to test directory name when generating output.  (Closed) 
  Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
    
  
    Issue 11280085:
  Add --checked or --minified to test directory name when generating output.  (Closed) 
  Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/| 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 /** | 5 /** | 
| 6 * Classes and methods for enumerating and preparing tests. | 6 * Classes and methods for enumerating and preparing tests. | 
| 7 * | 7 * | 
| 8 * This library includes: | 8 * This library includes: | 
| 9 * | 9 * | 
| 10 * - Creating tests by listing all the Dart files in certain directories, | 10 * - Creating tests by listing all the Dart files in certain directories, | 
| (...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1026 String createOutputDirectory(Path testPath, String optionsName) { | 1026 String createOutputDirectory(Path testPath, String optionsName) { | 
| 1027 Path relative = testPath.relativeTo(TestUtils.dartDir()); | 1027 Path relative = testPath.relativeTo(TestUtils.dartDir()); | 
| 1028 relative = relative.directoryPath.append(relative.filenameWithoutExtension); | 1028 relative = relative.directoryPath.append(relative.filenameWithoutExtension); | 
| 1029 String testUniqueName = relative.toString().replaceAll('/', '_'); | 1029 String testUniqueName = relative.toString().replaceAll('/', '_'); | 
| 1030 if (!optionsName.isEmpty) { | 1030 if (!optionsName.isEmpty) { | 
| 1031 testUniqueName = '$testUniqueName-$optionsName'; | 1031 testUniqueName = '$testUniqueName-$optionsName'; | 
| 1032 } | 1032 } | 
| 1033 | 1033 | 
| 1034 // Create '[build dir]/generated_tests/$compiler-$runtime/$testUniqueName', | 1034 // Create '[build dir]/generated_tests/$compiler-$runtime/$testUniqueName', | 
| 1035 // including any intermediate directories that don't exist. | 1035 // including any intermediate directories that don't exist. | 
| 1036 // If the tests are run in checked or minified mode we add that to the | |
| 1037 // '$compile-$runtime' directory name. | |
| 1038 var checked = configuration['checked'] ? '-checked' : ''; | |
| 1039 var minified = configuration['minified'] ? '-minified' : ''; | |
| 
ngeoffray
2012/11/20 10:32:28
Is configuration the list of flags passed to the c
 
ricow1
2012/11/26 13:27:23
No it is not, configuration is a ton of stuff
 | |
| 1040 var dirName = "${configuration['compiler']}-${configuration['runtime']}" | |
| 1041 "$checked$minified"; | |
| 1036 var generatedTestPath = Strings.join([ | 1042 var generatedTestPath = Strings.join([ | 
| 1037 buildDir, | 1043 buildDir, | 
| 1038 'generated_tests', | 1044 'generated_tests', | 
| 1039 "${configuration['compiler']}-${configuration['runtime']}", | 1045 dirName, | 
| 1040 testUniqueName | 1046 testUniqueName | 
| 1041 ], '/'); | 1047 ], '/'); | 
| 1042 | 1048 | 
| 1043 TestUtils.mkdirRecursive(new Path('.'), new Path(generatedTestPath)); | 1049 TestUtils.mkdirRecursive(new Path('.'), new Path(generatedTestPath)); | 
| 1044 return new File(generatedTestPath).fullPathSync().replaceAll('\\', '/'); | 1050 return new File(generatedTestPath).fullPathSync().replaceAll('\\', '/'); | 
| 1045 } | 1051 } | 
| 1046 | 1052 | 
| 1047 String get scriptType { | 1053 String get scriptType { | 
| 1048 switch (configuration['compiler']) { | 1054 switch (configuration['compiler']) { | 
| 1049 case 'none': | 1055 case 'none': | 
| (...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1671 * $pass tests are expected to pass | 1677 * $pass tests are expected to pass | 
| 1672 * $failOk tests are expected to fail that we won't fix | 1678 * $failOk tests are expected to fail that we won't fix | 
| 1673 * $fail tests are expected to fail that we should fix | 1679 * $fail tests are expected to fail that we should fix | 
| 1674 * $crash tests are expected to crash that we should fix | 1680 * $crash tests are expected to crash that we should fix | 
| 1675 * $timeout tests are allowed to timeout | 1681 * $timeout tests are allowed to timeout | 
| 1676 * $compileErrorSkip tests are skipped on browsers due to compile-time error | 1682 * $compileErrorSkip tests are skipped on browsers due to compile-time error | 
| 1677 """; | 1683 """; | 
| 1678 print(report); | 1684 print(report); | 
| 1679 } | 1685 } | 
| 1680 } | 1686 } | 
| OLD | NEW |