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

Unified Diff: tests/standalone/io/file_invalid_arguments_test.dart

Issue 16123036: Clean up dart:io exceptions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 6 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 | « tests/standalone/io/file_error_test.dart ('k') | tests/standalone/io/file_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/io/file_invalid_arguments_test.dart
diff --git a/tests/standalone/io/file_invalid_arguments_test.dart b/tests/standalone/io/file_invalid_arguments_test.dart
index 273a8c79d1b16994ed1018387566388d2a4f82d6..3ae9a9cbb537462bd5db507222bc9405124e8143 100644
--- a/tests/standalone/io/file_invalid_arguments_test.dart
+++ b/tests/standalone/io/file_invalid_arguments_test.dart
@@ -15,7 +15,7 @@ void testReadInvalidArgs(arg) {
file.readSync(arg);
Expect.fail('exception expected');
} catch (e) {
- Expect.isTrue(e is FileIOException);
+ Expect.isTrue(e is FileException);
Expect.isTrue(e.toString().contains('Invalid arguments'));
}
@@ -25,7 +25,7 @@ void testReadInvalidArgs(arg) {
Expect.fail('exception expected');
}).catchError((error) {
errors++;
- Expect.isTrue(error is FileIOException);
+ Expect.isTrue(error is FileException);
Expect.isTrue(error.toString().contains('Invalid arguments'));
file.close().then((ignore) {
Expect.equals(1, errors);
@@ -42,7 +42,7 @@ void testReadIntoInvalidArgs(buffer, start, end) {
file.readIntoSync(buffer, start, end);
Expect.fail('exception expected');
} catch (e) {
- Expect.isTrue(e is FileIOException);
+ Expect.isTrue(e is FileException);
Expect.isTrue(e.toString().contains('Invalid arguments'));
}
@@ -52,7 +52,7 @@ void testReadIntoInvalidArgs(buffer, start, end) {
Expect.fail('exception expected');
}).catchError((error) {
errors++;
- Expect.isTrue(error is FileIOException);
+ Expect.isTrue(error is FileException);
Expect.isTrue(error.toString().contains('Invalid arguments'));
file.close().then((ignore) {
Expect.equals(1, errors);
@@ -69,7 +69,7 @@ void testWriteByteInvalidArgs(value) {
file.writeByteSync(value);
Expect.fail('exception expected');
} catch (e) {
- Expect.isTrue(e is FileIOException);
+ Expect.isTrue(e is FileException);
Expect.isTrue(e.toString().contains('Invalid argument'));
}
@@ -77,7 +77,7 @@ void testWriteByteInvalidArgs(value) {
writeByteFuture.then((ignore) {
Expect.fail('exception expected');
}).catchError((error) {
- Expect.isTrue(error is FileIOException);
+ Expect.isTrue(error is FileException);
Expect.isTrue(error.toString().contains('Invalid argument'));
file.close().then((ignore) {
port.close();
@@ -93,7 +93,7 @@ void testWriteFromInvalidArgs(buffer, start, end) {
file.writeFromSync(buffer, start, end);
Expect.fail('exception expected');
} catch (e) {
- Expect.isTrue(e is FileIOException);
+ Expect.isTrue(e is FileException);
Expect.isTrue(e.toString().contains('Invalid arguments'));
}
@@ -101,7 +101,7 @@ void testWriteFromInvalidArgs(buffer, start, end) {
writeFromFuture.then((ignore) {
Expect.fail('exception expected');
}).catchError((error) {
- Expect.isTrue(error is FileIOException);
+ Expect.isTrue(error is FileException);
Expect.isTrue(error.toString().contains('Invalid arguments'));
file.close().then((ignore) {
port.close();
@@ -117,14 +117,14 @@ void testWriteStringInvalidArgs(string, encoding) {
file.writeStringSync(string, encoding: encoding);
Expect.fail('exception expected');
} catch (e) {
- Expect.isTrue(e is FileIOException);
+ Expect.isTrue(e is FileException);
}
var writeStringFuture = file.writeString(string, encoding: encoding);
writeStringFuture.then((ignore) {
Expect.fail('exception expected');
}).catchError((error) {
- Expect.isTrue(error is FileIOException);
+ Expect.isTrue(error is FileException);
file.close().then((ignore) {
port.close();
});
« no previous file with comments | « tests/standalone/io/file_error_test.dart ('k') | tests/standalone/io/file_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698