Skip to content

Commit

Permalink
[Test] Fixes sdk_hash_test broken by Windows line breaks.
Browse files Browse the repository at this point in the history
Change-Id: I4e87b39515e1e99197f7b03759234252b8cfa233
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/152653
Auto-Submit: Clement Skau <cskau@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
  • Loading branch information
Clement Skau authored and commit-bot@chromium.org committed Jun 26, 2020
1 parent edde575 commit 1a27811
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions runtime/tests/vm/dart/sdk_hash_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Future<void> main(List<String> args) async {
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals('', result.stderr);
Expect.equals(0, result.exitCode);
Expect.equals('Hello, SDK Hash!\n', result.stdout);
Expect.equals('Hello, SDK Hash!', result.stdout.trim());
}

// Invalidate the SDK hash in the kernel dill:
Expand All @@ -65,7 +65,7 @@ Future<void> main(List<String> args) async {
{
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals(
'Can\'t load Kernel binary: Invalid SDK hash.\n', result.stderr);
'Can\'t load Kernel binary: Invalid SDK hash.', result.stderr.trim());
Expect.equals(253, result.exitCode);
Expect.equals('', result.stdout);
}
Expand All @@ -82,7 +82,7 @@ Future<void> main(List<String> args) async {
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals('', result.stderr);
Expect.equals(0, result.exitCode);
Expect.equals('Hello, SDK Hash!\n', result.stdout);
Expect.equals('Hello, SDK Hash!', result.stdout.trim());
}
});
}
6 changes: 3 additions & 3 deletions runtime/tests/vm/dart_2/sdk_hash_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Future<void> main(List<String> args) async {
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals('', result.stderr);
Expect.equals(0, result.exitCode);
Expect.equals('Hello, SDK Hash!\n', result.stdout);
Expect.equals('Hello, SDK Hash!', result.stdout.trim());
}

// Invalidate the SDK hash in the kernel dill:
Expand All @@ -65,7 +65,7 @@ Future<void> main(List<String> args) async {
{
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals(
'Can\'t load Kernel binary: Invalid SDK hash.\n', result.stderr);
'Can\'t load Kernel binary: Invalid SDK hash.', result.stderr.trim());
Expect.equals(253, result.exitCode);
Expect.equals('', result.stdout);
}
Expand All @@ -82,7 +82,7 @@ Future<void> main(List<String> args) async {
final result = await Process.run(dart, [dillPath, '--child']);
Expect.equals('', result.stderr);
Expect.equals(0, result.exitCode);
Expect.equals('Hello, SDK Hash!\n', result.stdout);
Expect.equals('Hello, SDK Hash!', result.stdout.trim());
}
});
}

0 comments on commit 1a27811

Please sign in to comment.