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

Side by Side Diff: runtime/observatory/tests/service/evaluate_in_frame_rpc_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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 // VMOptions=--error_on_bad_type --error_on_bad_override 4 // VMOptions=--error_on_bad_type --error_on_bad_override
5 5
6 import 'dart:developer'; 6 import 'dart:developer';
7 import 'package:observatory/service_io.dart'; 7 import 'package:observatory/service_io.dart';
8 import 'package:unittest/unittest.dart'; 8 import 'package:unittest/unittest.dart';
9 import 'service_test_common.dart'; 9 import 'service_test_common.dart';
10 import 'test_helper.dart'; 10 import 'test_helper.dart';
11 11
12 void method(int value, _) { 12 void method(int value, _) {
13 debugger(); 13 debugger();
14 } 14 }
15 15
16 void testFunction() { 16 void testFunction() {
17 int i = 0; 17 int i = 0;
18 while (true) { 18 while (true) {
19 if (++i % 100000000 == 0) { 19 if (++i % 100000000 == 0) {
20 method(10000, 50); 20 method(10000, 50);
21 } 21 }
22 } 22 }
23 } 23 }
24 24
25 var tests = [ 25 var tests = [
26 26 hasStoppedAtBreakpoint,
27 hasStoppedAtBreakpoint,
28 27
29 // Evaluate against library, class, and instance. 28 // Evaluate against library, class, and instance.
30 (Isolate isolate) async { 29 (Isolate isolate) async {
31 var result; 30 var result;
32 result = await isolate.evalFrame(0, 'value'); 31 result = await isolate.evalFrame(0, 'value');
33 expect(result.valueAsString, equals('10000')); 32 expect(result.valueAsString, equals('10000'));
34 33
35 result = await isolate.evalFrame(0, '_'); 34 result = await isolate.evalFrame(0, '_');
36 expect(result.valueAsString, equals('50')); 35 expect(result.valueAsString, equals('50'));
37 36
38 result = await isolate.evalFrame(0, 'value + _'); 37 result = await isolate.evalFrame(0, 'value + _');
39 expect(result.valueAsString, equals('10050')); 38 expect(result.valueAsString, equals('10050'));
40 39
41 result = await isolate.evalFrame(1, 'i'); 40 result = await isolate.evalFrame(1, 'i');
42 expect(result.valueAsString, equals('100000000')); 41 expect(result.valueAsString, equals('100000000'));
43 }, 42 },
44
45 ]; 43 ];
46 44
47 main(args) => runIsolateTests(args, tests, testeeConcurrent: testFunction); 45 main(args) => runIsolateTests(args, tests, testeeConcurrent: testFunction);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698