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

Unified Diff: pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart

Issue 2976553002: Fix hot reload test (Closed)
Patch Set: Created 3 years, 5 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart
diff --git a/pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart b/pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart
index 45cd55bee410a50af4225ab41a0549ac40b39254..6b0d12bb059f064e709c6beece43c55b77f36f08 100644
--- a/pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart
+++ b/pkg/front_end/test/src/incremental/hot_reload_e2e_test.dart
@@ -53,7 +53,7 @@ main() {
startProgram(int reloadCount) async {
var vmArgs = [
'--enable-vm-service=0', // Note: use 0 to avoid port collisions.
- '--platform=${platformFile.toFilePath()}',
+ '--kernel-binaries=${sdkRoot.toFilePath()}',
outputUri.toFilePath()
];
vmArgs.add('$reloadCount');
@@ -98,7 +98,7 @@ main() {
test('initial program is valid', () async {
await startProgram(0);
await programIsDone;
- expect(await lines.skip(1).first, "part1 part2");
+ expect(await lines[1], "part1 part2");
});
test('reload after leaf library modification', () async {
@@ -156,7 +156,6 @@ main() {
var dartVm = Uri.base.resolve(Platform.resolvedExecutable);
var sdkRoot = dartVm.resolve("patched_sdk/");
-var platformFile = sdkRoot.resolve('platform.dill');
Future<IncrementalKernelGenerator> createIncrementalCompiler(
String entry, FileSystem fs) {
@@ -214,7 +213,12 @@ const sourceA = r'''
import 'dart:async';
import 'b.dart';
-void main(List<String> args) {
+void main(List<String> args) async {
+ // Note: this short delay is used to ensure the VM can initialize observatory
+ // first and we can obtain the port number as the first line in the output.
+ // If this becomes a source of flakiness, we can make the isolate pause on
+ // start and start the program via observatory instead.
ahe 2017/07/10 13:59:35 Let's to that proactively.
Siggi Cherem (dart-lang) 2017/07/10 19:31:11 Done.
+ await new Future.delayed(new Duration(milliseconds: 100));
var last = f();
print(last);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698