| Index: tools/testing/dart/html_test.dart
|
| diff --git a/tools/testing/dart/html_test.dart b/tools/testing/dart/html_test.dart
|
| index ef2119a2d325d39c7cf56206d7a2a944bcf92887..a3a3506aebe84936a68c8bc1d95f57f0645836c9 100644
|
| --- a/tools/testing/dart/html_test.dart
|
| +++ b/tools/testing/dart/html_test.dart
|
| @@ -44,4 +44,22 @@ HtmlTestInformation getInformation(String filename) {
|
| String getContents(HtmlTestInformation info) {
|
| String contents = new File(info.filePath.toNativePath()).readAsStringSync();
|
| return contents.replaceFirst(htmlAnnotation, '');
|
| -}
|
| +}
|
| +
|
| +String makeFailingHtmlFile(String message) {
|
| + return '''
|
| +<!DOCTYPE html>
|
| +<html>
|
| +<head>
|
| + <script>window.parent.dispatchEvent(new Event('detect_errors'));</script>
|
| + <title>Failing HTML test</title>
|
| +</head><body>
|
| + <h1>Failing HTML test</h1>
|
| + $message
|
| + <script>
|
| + throw "HTML test failed: $message";
|
| + </script>
|
| +</body>
|
| +</html>
|
| +''';
|
| +}
|
|
|