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

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

Issue 10351011: Change Platform members to getters instead of methods. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Adding new test binaries Created 8 years, 8 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/dart_std_io_pipe_test.dart ('k') | tests/standalone/io/directory_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/io/directory_error_test.dart
diff --git a/tests/standalone/io/directory_error_test.dart b/tests/standalone/io/directory_error_test.dart
index ed13aac50ac7ff8296d08fbd17d0d9e80fb51f0f..27d001b38709ff80b160ad695974e51b99f4cf38 100644
--- a/tests/standalone/io/directory_error_test.dart
+++ b/tests/standalone/io/directory_error_test.dart
@@ -18,13 +18,13 @@ bool checkCreateInNonExistentFileException(e) {
Expect.isTrue(e is DirectoryIOException);
Expect.isTrue(e.osError != null);
Expect.isTrue(e.toString().indexOf("Creation failed") != -1);
- if (Platform.operatingSystem() == "linux") {
+ if (Platform.operatingSystem == "linux") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "macos") {
+ } else if (Platform.operatingSystem == "macos") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "windows") {
+ } else if (Platform.operatingSystem == "windows") {
Expect.isTrue(
e.toString().indexOf(
"The system cannot find the path specified") != -1);
@@ -53,13 +53,13 @@ bool checkCreateTempInNonExistentFileException(e) {
Expect.isTrue(e.osError != null);
Expect.isTrue(e.toString().indexOf(
"Creation of temporary directory failed") != -1);
- if (Platform.operatingSystem() == "linux") {
+ if (Platform.operatingSystem == "linux") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "macos") {
+ } else if (Platform.operatingSystem == "macos") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "windows") {
+ } else if (Platform.operatingSystem == "windows") {
Expect.isTrue(
e.toString().indexOf(
"The system cannot find the path specified") != -1);
@@ -87,11 +87,11 @@ bool checkDeleteNonExistentFileException(e) {
Expect.isTrue(e is DirectoryIOException);
Expect.isTrue(e.osError != null);
Expect.isTrue(e.toString().indexOf("Deletion failed") != -1);
- if (Platform.operatingSystem() == "linux") {
+ if (Platform.operatingSystem == "linux") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
- } else if (Platform.operatingSystem() == "macos") {
+ } else if (Platform.operatingSystem == "macos") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
- } else if (Platform.operatingSystem() == "windows") {
+ } else if (Platform.operatingSystem == "windows") {
Expect.isTrue(
e.toString().indexOf(
"The system cannot find the file specified") != -1);
@@ -120,13 +120,13 @@ bool checkDeleteRecursivelyNonExistentFileException(e) {
Expect.isTrue(e is DirectoryIOException);
Expect.isTrue(e.osError != null);
Expect.isTrue(e.toString().indexOf("Deletion failed") != -1);
- if (Platform.operatingSystem() == "linux") {
+ if (Platform.operatingSystem == "linux") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "macos") {
+ } else if (Platform.operatingSystem == "macos") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "windows") {
+ } else if (Platform.operatingSystem == "windows") {
Expect.isTrue(
e.toString().indexOf(
"The system cannot find the path specified") != -1);
@@ -154,13 +154,13 @@ bool checkListNonExistentFileException(e) {
Expect.isTrue(e is DirectoryIOException);
Expect.isTrue(e.osError != null);
Expect.isTrue(e.toString().indexOf("Directory listing failed") != -1);
- if (Platform.operatingSystem() == "linux") {
+ if (Platform.operatingSystem == "linux") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "macos") {
+ } else if (Platform.operatingSystem == "macos") {
Expect.isTrue(e.toString().indexOf("No such file or directory") != -1);
Expect.equals(2, e.osError.errorCode);
- } else if (Platform.operatingSystem() == "windows") {
+ } else if (Platform.operatingSystem == "windows") {
Expect.isTrue(
e.toString().indexOf(
"The system cannot find the path specified") != -1);
« no previous file with comments | « tests/standalone/io/dart_std_io_pipe_test.dart ('k') | tests/standalone/io/directory_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698