Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(245)

Unified Diff: tools/testing/dart/multitest.dart

Issue 9662063: Fix some type and logical errors in test.dart, found by the Dart editor. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix a type error. Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/testing/dart/test_options.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/multitest.dart
diff --git a/tools/testing/dart/multitest.dart b/tools/testing/dart/multitest.dart
index 37af902889957b93efd26dd4b22c655f37fb584e..f88989eb2fd17bfe686a2effead70a0ee238d417 100644
--- a/tools/testing/dart/multitest.dart
+++ b/tools/testing/dart/multitest.dart
@@ -57,7 +57,7 @@ void ExtractTestsFromMultitest(String filename,
// Read the entire file into a byte buffer and transform it to a
// String. This will treat the file as ascii but the only parts
// we are interested in will be ascii in any case.
- RandomAccessFile file = (new File(filename)).openSync();
+ RandomAccessFile file = (new File(filename)).openSync(FileMode.READ);
List chars = new List(file.lengthSync());
int offset = 0;
while (offset != chars.length) {
@@ -172,7 +172,7 @@ void DoMultitest(String filename,
[bool isNegativeIfChecked,
bool hasFatalTypeErrors,
bool hasRuntimeErrors,
- String multitestOutcome]),
+ Set<String> multitestOutcome]),
Function multitestDone) {
// Each new test is a single String value in the Map tests.
Map<String, String> tests = new Map<String, String>();
@@ -200,8 +200,8 @@ void DoMultitest(String filename,
TestUtils.copyFile(source, dest);
}
for (String key in tests.getKeys()) {
- final String filename = '$directory/${baseFilename}_$key.dart';
- final File file = new File(filename);
+ final String multitestFilename = '$directory/${baseFilename}_$key.dart';
+ final File file = new File(multitestFilename);
file.createSync();
RandomAccessFile openedFile = file.openSync(FileMode.WRITE);
@@ -214,7 +214,7 @@ void DoMultitest(String filename,
bool isNegative = hasRuntimeErrors
|| outcome.contains('compile-time error');
bool isNegativeIfChecked = outcome.contains('dynamic type error');
- doTest(filename,
+ doTest(multitestFilename,
isNegative,
isNegativeIfChecked,
enableFatalTypeErrors,
« no previous file with comments | « no previous file | tools/testing/dart/test_options.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698