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

Side by Side Diff: tests/compiler/dart2js/serialization/library_test.dart

Issue 2879593004: Reorganize equivalence test helpers (Closed)
Patch Set: Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library dart2js.serialization_library_test; 5 library dart2js.serialization_library_test;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:io'; 8 import 'dart:io';
9 import '../memory_compiler.dart';
10 import 'package:async_helper/async_helper.dart'; 9 import 'package:async_helper/async_helper.dart';
11 import 'package:compiler/src/common.dart';
12 import 'package:compiler/src/commandline_options.dart'; 10 import 'package:compiler/src/commandline_options.dart';
13 import 'package:compiler/src/common/names.dart'; 11 import 'package:compiler/src/common/names.dart';
14 import 'package:compiler/src/compiler.dart'; 12 import 'package:compiler/src/compiler.dart';
15 import 'package:compiler/src/diagnostics/invariant.dart'; 13 import 'package:compiler/src/diagnostics/invariant.dart';
16 import 'package:compiler/src/elements/elements.dart'; 14 import 'package:compiler/src/elements/elements.dart';
17 import 'package:compiler/src/serialization/json_serializer.dart'; 15 import 'package:compiler/src/serialization/json_serializer.dart';
18 import 'package:compiler/src/serialization/serialization.dart'; 16 import 'package:compiler/src/serialization/serialization.dart';
19 import 'package:expect/expect.dart'; 17 import 'package:expect/expect.dart';
20 18 import '../equivalence/check_functions.dart';
19 import '../memory_compiler.dart';
21 import 'equivalence_test.dart'; 20 import 'equivalence_test.dart';
22 import 'test_helper.dart';
23 import 'resolved_ast_test.dart';
24 import 'helper.dart'; 21 import 'helper.dart';
25 22
26 main(List<String> arguments) { 23 main(List<String> arguments) {
27 // Ensure that we can print out constant expressions. 24 // Ensure that we can print out constant expressions.
28 DEBUG_MODE = true; 25 DEBUG_MODE = true;
29 26
30 Uri entryPoint; 27 Uri entryPoint;
31 String outPath; 28 String outPath;
32 int shardCount = 3; 29 int shardCount = 3;
33 bool prettyPrint = false; 30 bool prettyPrint = false;
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 compiler2.libraryLoader.lookupLibrary(library1.canonicalUri); 126 compiler2.libraryLoader.lookupLibrary(library1.canonicalUri);
130 if (library2 == null) { 127 if (library2 == null) {
131 throw new ArgumentError('No library ${library1.canonicalUri} found.'); 128 throw new ArgumentError('No library ${library1.canonicalUri} found.');
132 } 129 }
133 checkLibraryContent('library1', 'library2', 'library', library1, library2); 130 checkLibraryContent('library1', 'library2', 'library', library1, library2);
134 checkAllResolvedAsts(compiler1, compiler2); 131 checkAllResolvedAsts(compiler1, compiler2);
135 checkAllImpacts(compiler1, compiler2); 132 checkAllImpacts(compiler1, compiler2);
136 } 133 }
137 Expect.isFalse(compiler2.reporter.hasReportedError, "Unexpected errors"); 134 Expect.isFalse(compiler2.reporter.hasReportedError, "Unexpected errors");
138 } 135 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698