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

Unified Diff: tests/compiler/dart2js/mirrors_used_test.dart

Issue 263103003: Remove warnings from dart2js test-suite. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove debug code. Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/compiler/dart2js/mirror_tree_shaking_test.dart ('k') | tests/compiler/dart2js/parser_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/mirrors_used_test.dart
diff --git a/tests/compiler/dart2js/mirrors_used_test.dart b/tests/compiler/dart2js/mirrors_used_test.dart
index ba2afed7e759516e56d85826359a607bb56d076a..f2656a2882fdfe8737b93c2d1c70ce7f32b0e455 100644
--- a/tests/compiler/dart2js/mirrors_used_test.dart
+++ b/tests/compiler/dart2js/mirrors_used_test.dart
@@ -21,8 +21,9 @@ import '../../../sdk/lib/_internal/compiler/implementation/dart2jslib.dart' show
import
'../../../sdk/lib/_internal/compiler/implementation/elements/elements.dart'
-show
- Elements;
+show Element, Elements;
+import '../../../sdk/lib/_internal/compiler/implementation/js_backend/js_backend.dart'
+ show JavaScriptBackend;
void expectOnlyVerboseInfo(Uri uri, int begin, int end, String message, kind) {
if (kind.name == 'verbose info') {
@@ -81,15 +82,15 @@ void main() {
compiler.stringClass, compiler.boolClass, compiler.nullClass,
compiler.listClass
];
-
+ JavaScriptBackend backend = compiler.backend;
Iterable<String> nativeNames =
- nativeClasses.map(compiler.backend.namer.getNameOfClass);
+ nativeClasses.map(backend.namer.getNameOfClass);
expectedNames.addAll(nativeNames);
Set recordedNames = new Set()
- ..addAll(compiler.backend.emitter.recordedMangledNames)
- ..addAll(compiler.backend.emitter.mangledFieldNames.keys)
- ..addAll(compiler.backend.emitter.mangledGlobalFieldNames.keys);
+ ..addAll(backend.emitter.recordedMangledNames)
+ ..addAll(backend.emitter.mangledFieldNames.keys)
+ ..addAll(backend.emitter.mangledGlobalFieldNames.keys);
Expect.setEquals(new Set.from(expectedNames), recordedNames);
for (var library in compiler.libraries.values) {
@@ -111,13 +112,12 @@ void main() {
// There should at least be one metadata constant:
// 1. The constructed constant for 'MirrorsUsed'.
- Expect.isTrue(compiler.backend.metadataConstants.length >= 1);
+ Expect.isTrue(backend.metadataConstants.length >= 1);
- Set<Constant> compiledConstants =
- compiler.backend.constants.compiledConstants;
+ Set<Constant> compiledConstants = backend.constants.compiledConstants;
// Make sure that most of the metadata constants aren't included in the
// generated code.
- for (var dependency in compiler.backend.metadataConstants) {
+ for (var dependency in backend.metadataConstants) {
Constant constant = dependency.constant;
Expect.isFalse(compiledConstants.contains(constant), '$constant');
}
« no previous file with comments | « tests/compiler/dart2js/mirror_tree_shaking_test.dart ('k') | tests/compiler/dart2js/parser_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698