mirror of
https://github.com/dart-lang/sdk
synced 2024-09-18 21:51:18 +00:00
0ba8d4ef77
TEST=pkg/vm_service/test/column_breakpoint_test.dart, other debugger tests in tryjobs Fixes: https://github.com/dart-lang/sdk/issues/51563 Change-Id: I87ef7e52cfc7e922904b267b7eb74fc783214b44 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/316440 Reviewed-by: Ben Konyi <bkonyi@google.com> Commit-Queue: Derek Xu <derekx@google.com>
43 lines
1.1 KiB
Dart
43 lines
1.1 KiB
Dart
// Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
import 'common/service_test_common.dart';
|
|
import 'common/test_helper.dart';
|
|
|
|
void testMain() {
|
|
var b = [1, 2].map((i) => i == 0).toList();
|
|
print(b.length);
|
|
}
|
|
|
|
const int LINE = 9;
|
|
const int COLUMN = 29;
|
|
const String shortFile = "column_breakpoint_test.dart";
|
|
|
|
List<String> stops = [];
|
|
|
|
const List<String> expected = [
|
|
"$shortFile:${LINE + 0}:29", // on 'i == 0'
|
|
"$shortFile:${LINE + 0}:29", // iterate twice
|
|
"$shortFile:${LINE + 1}:11" //on 'b.length'
|
|
];
|
|
|
|
final tests = <IsolateTest>[
|
|
hasPausedAtStart,
|
|
setBreakpointAtLineColumn(LINE, COLUMN), // on 'i == 0'
|
|
setBreakpointAtLineColumn(LINE + 1, 9), // on 'b.length'
|
|
resumeProgramRecordingStops(stops, false),
|
|
checkRecordedStops(stops, expected),
|
|
];
|
|
|
|
main(args) {
|
|
runIsolateTestsSynchronous(
|
|
args,
|
|
tests,
|
|
'column_breakpoint_test.dart',
|
|
testeeConcurrent: testMain,
|
|
pause_on_start: true,
|
|
pause_on_exit: true,
|
|
);
|
|
}
|