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

Unified Diff: tests/lib/async/stack_trace20_test.dart

Issue 25094002: Adapt streams for additional stackTrace argument. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove types in closures. Created 7 years, 2 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/lib/async/stack_trace10_test.dart ('k') | tests/lib/async/stack_trace21_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/async/stack_trace20_test.dart
diff --git a/tests/lib/async/stack_trace14_test.dart b/tests/lib/async/stack_trace20_test.dart
similarity index 67%
copy from tests/lib/async/stack_trace14_test.dart
copy to tests/lib/async/stack_trace20_test.dart
index 1a75c88c56d751b576bde8a9ee2adc815921c7dc..aaec9982b0e85947d03d53759706d16802f16fd4 100644
--- a/tests/lib/async/stack_trace14_test.dart
+++ b/tests/lib/async/stack_trace20_test.dart
@@ -16,12 +16,18 @@ StackTrace captureStackTrace() {
main() {
StackTrace trace = captureStackTrace();
+ var controller;
+ controller = new StreamController(onListen: () {
+ controller.addError("error", trace);
+ controller.close();
+ });
asyncStart();
- var f = new Future(() => 499);
- f.then((_) => new Future.error("e", trace))
- .then((_) { throw "Unreachable"; },
+ controller.stream
+ .listen(null)
+ .asFuture()
+ .then((_) { throw "should never be reached"; },
onError: (e, st) {
- Expect.equals("e", e);
+ Expect.equals("error", e);
Expect.identical(trace, st);
asyncEnd();
});
« no previous file with comments | « tests/lib/async/stack_trace10_test.dart ('k') | tests/lib/async/stack_trace21_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698