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

Unified Diff: tests/lib/async/stack_trace24_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_trace21_test.dart ('k') | tests/lib/async/stack_trace25_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/async/stack_trace24_test.dart
diff --git a/tests/lib/async/stack_trace13_test.dart b/tests/lib/async/stack_trace24_test.dart
similarity index 59%
copy from tests/lib/async/stack_trace13_test.dart
copy to tests/lib/async/stack_trace24_test.dart
index 0b12808dd4af08685b89c3aee1603e97ee9baecd..929b42d561cc8cf461c8270e749af1ca55246151 100644
--- a/tests/lib/async/stack_trace13_test.dart
+++ b/tests/lib/async/stack_trace24_test.dart
@@ -7,14 +7,20 @@ import 'package:async_helper/async_helper.dart';
import 'dart:async';
main() {
- StackTrace trace;
+ var controller;
+ controller = new StreamController(onListen: () {
+ controller.add(499);
+ controller.close();
+ });
asyncStart();
- var f = new Future(() { throw "foo"; });
- f.then((_) => 499)
- .then((_) { throw "Unreachable"; },
+ controller.stream
+ .map((e) { throw "error"; })
+ .listen((_) { throw "should never be reached"; },
onError: (e, st) {
- Expect.equals("foo", e);
+ Expect.equals("error", e);
Expect.isNotNull(st);
+ },
+ onDone: () {
asyncEnd();
});
}
« no previous file with comments | « tests/lib/async/stack_trace21_test.dart ('k') | tests/lib/async/stack_trace25_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698