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

Unified Diff: test/dependency_graph_test.dart

Issue 1130093007: Create html if needed in server mode (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Address comments Created 5 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 | « lib/src/testing.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/dependency_graph_test.dart
diff --git a/test/dependency_graph_test.dart b/test/dependency_graph_test.dart
index 48b4bf313d7977d79af95775acab04ae531e9f6b..a9b7e6d99324195b6aecd47e1bdad76b5550c8a9 100644
--- a/test/dependency_graph_test.dart
+++ b/test/dependency_graph_test.dart
@@ -8,7 +8,7 @@ import 'package:unittest/unittest.dart';
import 'package:dev_compiler/src/checker/dart_sdk.dart'
show mockSdkSources, dartSdkDirectory;
-import 'package:dev_compiler/src/testing.dart';
+import 'package:dev_compiler/src/in_memory.dart';
import 'package:dev_compiler/src/options.dart';
import 'package:dev_compiler/src/checker/resolver.dart';
import 'package:dev_compiler/src/dependency_graph.dart';
@@ -61,7 +61,7 @@ void main() {
setUp(() {
/// We completely reset the TestUriResolver to avoid interference between
/// tests (since some tests modify the state of the files).
- testUriResolver = new TestUriResolver(testFiles);
+ testUriResolver = new InMemoryUriResolver(testFiles);
context = new TypeResolver.fromMock(mockSdkSources, options,
otherResolvers: [testUriResolver]).context;
graph = new SourceGraph(context, new LogReporter(), options);
@@ -1109,8 +1109,8 @@ void main() {
group('null for non-existing files', () {
setUp(() {
- testUriResolver =
- new TestUriResolver(testFiles, representNonExistingFiles: false);
+ testUriResolver = new InMemoryUriResolver(testFiles,
+ representNonExistingFiles: false);
context = new TypeResolver.fromMock(mockSdkSources, options,
otherResolvers: [testUriResolver]).context;
graph = new SourceGraph(context, new LogReporter(), options);
@@ -1119,7 +1119,7 @@ void main() {
test('recognize locally change between existing and not-existing', () {
var n = nodeOf('/foo.dart');
expect(n.source, isNull);
- var source = new TestSource(new Uri.file('/foo.dart'), "hi");
+ var source = new InMemorySource(new Uri.file('/foo.dart'), "hi");
testUriResolver.files[source.uri] = source;
expect(n.source, isNull);
n.update(graph);
@@ -1130,7 +1130,7 @@ void main() {
test('non-existing files are tracked in dependencies', () {
var s1 =
- new TestSource(new Uri.file('/foo.dart'), "import 'bar.dart';");
+ new InMemorySource(new Uri.file('/foo.dart'), "import 'bar.dart';");
testUriResolver.files[s1.uri] = s1;
var node = nodeOf('/foo.dart');
rebuild(node, graph, buildNoTransitiveChange);
@@ -1138,7 +1138,7 @@ void main() {
expect(node.allDeps.contains(nodeOf('/bar.dart')), isTrue);
expect(nodeOf('/bar.dart').source, isNull);
- var s2 = new TestSource(new Uri.file('/bar.dart'), "hi");
+ var s2 = new InMemorySource(new Uri.file('/bar.dart'), "hi");
testUriResolver.files[s2.uri] = s2;
results = [];
rebuild(node, graph, buildWithTransitiveChange);
« no previous file with comments | « lib/src/testing.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698