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

Unified Diff: runtime/observatory/tests/service/capture_stdio_test.dart

Issue 2759973004: Fix observatory tests broken by running dartfmt. Temporarily reverted formatting for evaluate_activ… (Closed)
Patch Set: Created 3 years, 9 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
Index: runtime/observatory/tests/service/capture_stdio_test.dart
diff --git a/runtime/observatory/tests/service/capture_stdio_test.dart b/runtime/observatory/tests/service/capture_stdio_test.dart
index 294de12d35c50389b03f6c334c2f5a0702d29412..616fbb6eda3b329c9019fcd3b0d87ee111786ed3 100644
--- a/runtime/observatory/tests/service/capture_stdio_test.dart
+++ b/runtime/observatory/tests/service/capture_stdio_test.dart
@@ -24,67 +24,58 @@ void test() {
var tests = [
hasStoppedAtBreakpoint,
-
(Isolate isolate) async {
Completer completer = new Completer();
var stdoutSub;
- stdoutSub = await isolate.vm.listenEventStream(
- VM.kStdoutStream,
- (ServiceEvent event) {
- expect(event.kind, equals('WriteEvent'));
- expect(event.bytesAsString, equals('stdout'));
- stdoutSub.cancel().then((_) {
- completer.complete();
- });
+ stdoutSub = await isolate.vm.listenEventStream(VM.kStdoutStream,
+ (ServiceEvent event) {
+ expect(event.kind, equals('WriteEvent'));
+ expect(event.bytesAsString, equals('stdout'));
+ stdoutSub.cancel().then((_) {
+ completer.complete();
});
+ });
await isolate.resume();
await completer.future;
},
-
hasStoppedAtBreakpoint,
-
(Isolate isolate) async {
Completer completer = new Completer();
var stdoutSub;
int eventNumber = 1;
- stdoutSub = await isolate.vm.listenEventStream(
- VM.kStdoutStream,
- (ServiceEvent event) {
- expect(event.kind, equals('WriteEvent'));
- if (eventNumber == 1) {
- expect(event.bytesAsString, equals('print'));
- } else if (eventNumber == 2) {
- expect(event.bytesAsString, equals('\n'));
- stdoutSub.cancel().then((_) {
- completer.complete();
- });
- } else {
- expect(true, false);
- }
- eventNumber++;
- });
+ stdoutSub = await isolate.vm.listenEventStream(VM.kStdoutStream,
+ (ServiceEvent event) {
+ expect(event.kind, equals('WriteEvent'));
+ if (eventNumber == 1) {
+ expect(event.bytesAsString, equals('print'));
+ } else if (eventNumber == 2) {
+ expect(event.bytesAsString, equals('\n'));
+ stdoutSub.cancel().then((_) {
+ completer.complete();
+ });
+ } else {
+ expect(true, false);
+ }
+ eventNumber++;
+ });
await isolate.resume();
await completer.future;
},
-
hasStoppedAtBreakpoint,
-
(Isolate isolate) async {
Completer completer = new Completer();
var stderrSub;
- stderrSub = await isolate.vm.listenEventStream(
- VM.kStderrStream,
- (ServiceEvent event) {
- expect(event.kind, equals('WriteEvent'));
- expect(event.bytesAsString, equals('stderr'));
- stderrSub.cancel().then((_) {
- completer.complete();
- });
+ stderrSub = await isolate.vm.listenEventStream(VM.kStderrStream,
+ (ServiceEvent event) {
+ expect(event.kind, equals('WriteEvent'));
+ expect(event.bytesAsString, equals('stderr'));
+ stderrSub.cancel().then((_) {
+ completer.complete();
});
+ });
await isolate.resume();
await completer.future;
},
];
-
main(args) => runIsolateTests(args, tests, testeeConcurrent: test);

Powered by Google App Engine
This is Rietveld 408576698