| Index: runtime/observatory/tests/service/add_breakpoint_rpc_test.dart
|
| diff --git a/runtime/observatory/tests/service/add_breakpoint_rpc_test.dart b/runtime/observatory/tests/service/add_breakpoint_rpc_test.dart
|
| index f1b3a1027899f63ab80d4729e055b1ea5864eaab..a51a2b3399a5cc3ad4793802044aa63bbbac8923 100644
|
| --- a/runtime/observatory/tests/service/add_breakpoint_rpc_test.dart
|
| +++ b/runtime/observatory/tests/service/add_breakpoint_rpc_test.dart
|
| @@ -8,7 +8,6 @@ import 'package:unittest/unittest.dart';
|
| import 'test_helper.dart';
|
| import 'deferred_library.dart' deferred as deferredLib;
|
| import 'dart:async';
|
| -import 'dart:developer' as developer;
|
|
|
| int value = 0;
|
|
|
| @@ -18,9 +17,9 @@ int incValue(int amount) {
|
| }
|
|
|
| Future testMain() async {
|
| - incValue(incValue(1)); // line 21
|
| + incValue(incValue(1)); // line 20
|
|
|
| - incValue(incValue(1)); // line 23
|
| + incValue(incValue(1)); // line 22
|
|
|
| await deferredLib.loadLibrary();
|
| deferredLib.deferredTest();
|
| @@ -36,17 +35,17 @@ var tests = [
|
| var script = rootLib.scripts[0];
|
|
|
| // Future breakpoint.
|
| - var futureBpt1 = await isolate.addBreakpoint(script, 21);
|
| + var futureBpt1 = await isolate.addBreakpoint(script, 20);
|
| expect(futureBpt1.number, equals(1));
|
| expect(futureBpt1.resolved, isFalse);
|
| - expect(await futureBpt1.location.getLine(), equals(21));
|
| + expect(await futureBpt1.location.getLine(), equals(20));
|
| expect(await futureBpt1.location.getColumn(), equals(null));
|
|
|
| // Future breakpoint with specific column.
|
| - var futureBpt2 = await isolate.addBreakpoint(script, 21, 3);
|
| + var futureBpt2 = await isolate.addBreakpoint(script, 20, 3);
|
| expect(futureBpt2.number, equals(2));
|
| expect(futureBpt2.resolved, isFalse);
|
| - expect(await futureBpt2.location.getLine(), equals(21));
|
| + expect(await futureBpt2.location.getLine(), equals(20));
|
| expect(await futureBpt2.location.getColumn(), equals(3));
|
|
|
| var stream = await isolate.vm.getEventStream(VM.kDebugStream);
|
| @@ -68,10 +67,10 @@ var tests = [
|
| // After resolution the breakpoints have assigned line & column.
|
| expect(resolvedCount, equals(2));
|
| expect(futureBpt1.resolved, isTrue);
|
| - expect(await futureBpt1.location.getLine(), equals(21));
|
| + expect(await futureBpt1.location.getLine(), equals(20));
|
| expect(await futureBpt1.location.getColumn(), equals(12));
|
| expect(futureBpt2.resolved, isTrue);
|
| - expect(await futureBpt2.location.getLine(), equals(21));
|
| + expect(await futureBpt2.location.getLine(), equals(20));
|
| expect(await futureBpt2.location.getColumn(), equals(3));
|
|
|
| // The first breakpoint hits before value is modified.
|
| @@ -177,19 +176,19 @@ var tests = [
|
| var script = isolate.rootLibrary.scripts[0];
|
| // Try all columns, including some columns that are too big.
|
| for (int col = 1; col <= 50; col++) {
|
| - var bpt = await isolate.addBreakpoint(script, 21, col);
|
| + var bpt = await isolate.addBreakpoint(script, 20, col);
|
| expect(bpt.resolved, isTrue);
|
| int resolvedLine = await bpt.location.getLine();
|
| int resolvedCol = await bpt.location.getColumn();
|
| - print('21:${col} -> ${resolvedLine}:${resolvedCol}');
|
| + print('20:${col} -> ${resolvedLine}:${resolvedCol}');
|
| if (col <= 10) {
|
| - expect(resolvedLine, equals(21));
|
| + expect(resolvedLine, equals(20));
|
| expect(resolvedCol, equals(3));
|
| } else if (col <= 19) {
|
| - expect(resolvedLine, equals(21));
|
| + expect(resolvedLine, equals(20));
|
| expect(resolvedCol, equals(12));
|
| } else {
|
| - expect(resolvedLine, equals(23));
|
| + expect(resolvedLine, equals(22));
|
| expect(resolvedCol, equals(12));
|
| }
|
| expect((await isolate.removeBreakpoint(bpt)).type, equals('Success'));
|
| @@ -198,7 +197,7 @@ var tests = [
|
| // Make sure that a zero column is an error.
|
| var caughtException = false;
|
| try {
|
| - await isolate.addBreakpoint(script, 21, 0);
|
| + await isolate.addBreakpoint(script, 20, 0);
|
| expect(false, isTrue, reason:'Unreachable');
|
| } on ServerRpcException catch(e) {
|
| caughtException = true;
|
|
|