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

Unified Diff: pkg/front_end/test/fasta/uri_translator_test.dart

Issue 2986303003: Switch FE to use the libraries.json format. (Closed)
Patch Set: fix issues found on bots Created 3 years, 4 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
Index: pkg/front_end/test/fasta/uri_translator_test.dart
diff --git a/pkg/front_end/test/fasta/uri_translator_test.dart b/pkg/front_end/test/fasta/uri_translator_test.dart
index 27ca3c868e130790bc82921e854e6fc8b2d1680c..e15cde8cd2a9f33fbd48c5df69e1c7cbbcc3c383 100644
--- a/pkg/front_end/test/fasta/uri_translator_test.dart
+++ b/pkg/front_end/test/fasta/uri_translator_test.dart
@@ -2,6 +2,7 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+import 'package:front_end/src/base/libraries_specification.dart';
import 'package:front_end/src/fasta/uri_translator_impl.dart';
import 'package:package_config/packages.dart';
import 'package:test/test.dart';
@@ -15,12 +16,16 @@ main() {
@reflectiveTest
class UriTranslatorImplTest {
- void test_isPlatformImplementation() {
- var translator = new UriTranslatorImpl({
- 'core': Uri.parse('file:///sdk/core/core.dart'),
- 'math': Uri.parse('file:///sdk/math/math.dart')
- }, {}, Packages.noPackages);
+ UriTranslatorImpl translator = new UriTranslatorImpl(
+ new TargetLibrariesSpecification('vm', {
+ 'core': new LibraryInfo(
+ 'core', Uri.parse('file:///sdk/core/core.dart'), const []),
+ 'math': new LibraryInfo(
+ 'core', Uri.parse('file:///sdk/math/math.dart'), const []),
+ }),
+ Packages.noPackages);
+ void test_isPlatformImplementation() {
bool isPlatform(String uriStr) {
var uri = Uri.parse(uriStr);
return translator.isPlatformImplementation(uri);
@@ -33,11 +38,6 @@ class UriTranslatorImplTest {
}
void test_translate_dart() {
- var translator = new UriTranslatorImpl({
- 'core': Uri.parse('file:///sdk/core/core.dart'),
- 'math': Uri.parse('file:///sdk/math/math.dart')
- }, {}, Packages.noPackages);
-
expect(translator.translate(Uri.parse('dart:core')),
Uri.parse('file:///sdk/core/core.dart'));
expect(translator.translate(Uri.parse('dart:core/string.dart')),
« no previous file with comments | « pkg/front_end/test/fasta/testing/suite.dart ('k') | pkg/front_end/test/incremental_kernel_generator_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698