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

Unified Diff: lib/src/runner/browser/suite.dart

Issue 1664433002: Support shelf 0.7.0. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Code review changes Created 4 years, 11 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 | « lib/src/runner/browser/static/host.dart ('k') | lib/src/util/multi_channel.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/runner/browser/suite.dart
diff --git a/lib/src/runner/browser/suite.dart b/lib/src/runner/browser/suite.dart
index a0c9e3ab3eaf73f474ffd4cc2be8e8c191bbc845..0e8d3c3e71511faaaf55582dd9f122d6a3c724da 100644
--- a/lib/src/runner/browser/suite.dart
+++ b/lib/src/runner/browser/suite.dart
@@ -5,15 +5,14 @@
import 'dart:async';
import 'package:async/async.dart';
+import 'package:stream_channel/stream_channel.dart';
import '../../backend/group.dart';
import '../../backend/metadata.dart';
import '../../backend/test.dart';
import '../../backend/test_platform.dart';
-import '../../util/multi_channel.dart';
import '../../util/remote_exception.dart';
import '../../util/stack_trace_mapper.dart';
-import '../../util/stream_channel.dart';
import '../../utils.dart';
import '../environment.dart';
import '../load_exception.dart';
@@ -51,16 +50,18 @@ Future<RunnerSuite> loadBrowserSuite(StreamChannel channel,
// Even though [channel] is probably a [MultiChannel] already, create a
// nested MultiChannel because the iframe will be using a channel wrapped
// within the host's channel.
- var suiteChannel = new MultiChannel(channel.stream.map((message) {
- // Whenever we get a message, no matter which child channel it's for, we the
- // browser is still running code which means the using isn't debugging.
- if (controller != null) {
- timer.reset();
- controller.setDebugging(false);
- }
-
- return message;
- }), channel.sink);
+ var suiteChannel = new MultiChannel(channel.changeStream((stream) {
+ return stream.map((message) {
+ // Whenever we get a message, no matter which child channel it's for, we the
+ // browser is still running code which means the using isn't debugging.
+ if (controller != null) {
+ timer.reset();
+ controller.setDebugging(false);
+ }
+
+ return message;
+ });
+ }));
var response = await _getResponse(suiteChannel.stream)
.timeout(new Duration(minutes: 1), onTimeout: () {
« no previous file with comments | « lib/src/runner/browser/static/host.dart ('k') | lib/src/util/multi_channel.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698