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

Unified Diff: tests/standalone/src/StringStreamTest.dart

Issue 8477026: Change the handling of the close event in the StringInputStream (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years, 1 month 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 | « runtime/bin/string_stream.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/src/StringStreamTest.dart
diff --git a/tests/standalone/src/StringStreamTest.dart b/tests/standalone/src/StringStreamTest.dart
index f6d70fb1c5d1f7329da42c867b63591fdd690e1f..9c7f3718b85fa339e7d5801180e7ff0d9417cd1c 100644
--- a/tests/standalone/src/StringStreamTest.dart
+++ b/tests/standalone/src/StringStreamTest.dart
@@ -121,7 +121,13 @@ void testReadLine1() {
stage++;
}
}
+
+ void streamClosed() {
+ Expect.equals(2, stage);
+ }
+
stream.dataHandler = stringData;
+ stream.closeHandler = streamClosed;
s.write("Line".charCodes());
Expect.equals(2, stage);
}
@@ -172,7 +178,13 @@ void testReadLine2() {
stage++;
}
}
+
+ void streamClosed() {
+ Expect.equals(4, stage);
+ }
+
stream.dataHandler = stringData;
+ stream.closeHandler = streamClosed;
s.write("Line1\nLine2\r\nLine3\rLi".charCodes());
Expect.equals(4, stage);
}
« no previous file with comments | « runtime/bin/string_stream.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698