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

Unified Diff: dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java

Issue 11233061: Revert "Parts must start with 'part of'" and "Attempt to fix VM build" (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 2 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: dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java
diff --git a/dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java b/dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java
index 1db168b98ee03c5b8881898b03b9ee4ceac5e80c..64209dddf7a70eb2b8a2f67ec3fa3e0eea8e1db9 100644
--- a/dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java
+++ b/dart/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/analysis/ScanTaskTest.java
@@ -13,6 +13,12 @@
*/
package com.google.dart.tools.core.analysis;
+import com.google.common.collect.Lists;
+import com.google.dart.compiler.PackageLibraryManager;
+import com.google.dart.engine.utilities.io.PrintStringWriter;
+import com.google.dart.tools.core.analysis.ScanTask.DartFileType;
+import com.google.dart.tools.core.internal.model.PackageLibraryManagerProvider;
+
import static com.google.dart.tools.core.analysis.AnalysisTestUtilities.assertCachedLibraries;
import static com.google.dart.tools.core.analysis.AnalysisTestUtilities.assertPackageContexts;
import static com.google.dart.tools.core.analysis.AnalysisTestUtilities.assertTrackedLibraryFiles;
@@ -20,12 +26,6 @@ import static com.google.dart.tools.core.analysis.ScanTask.DartFileType.Library;
import static com.google.dart.tools.core.analysis.ScanTask.DartFileType.PartOf;
import static com.google.dart.tools.core.analysis.ScanTask.DartFileType.Unknown;
-import com.google.common.collect.Lists;
-import com.google.dart.compiler.PackageLibraryManager;
-import com.google.dart.engine.utilities.io.PrintStringWriter;
-import com.google.dart.tools.core.analysis.ScanTask.DartFileType;
-import com.google.dart.tools.core.internal.model.PackageLibraryManagerProvider;
-
import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.IOException;
@@ -52,30 +52,6 @@ public class ScanTaskTest extends AbstractDartAnalysisTest {
private AnalysisServerAdapter server;
private Listener listener;
- /**
- * TODO(scheglov) disabled because now 'part of' directive required
- */
- public void _test_scan_source() throws Exception {
- assertTrackedLibraryFiles(server);
- server.scan(simpleMoneySrcFile, null);
- server.start();
- listener.waitForIdle(1, FIVE_MINUTES_MS);
- assertTrackedLibraryFiles(server, simpleMoneySrcFile);
- server.assertAnalyzeContext(true);
- }
-
- /**
- * TODO(scheglov) disabled because now 'part of' directive required
- */
- public void _test_scan_sourceThenLibrary() throws Exception {
- _test_scan_source();
- server.resetAnalyzeContext();
- server.scan(moneyLibFile, null);
- listener.waitForIdle(2, FIVE_MINUTES_MS);
- assertTrackedLibraryFiles(server, moneyLibFile);
- server.assertAnalyzeContext(true);
- }
-
public void test_packages_preference() throws Exception {
PackageLibraryManager libMgr = PackageLibraryManagerProvider.getAnyLibraryManager();
assertTrackedLibraryFiles(server);
@@ -149,6 +125,24 @@ public class ScanTaskTest extends AbstractDartAnalysisTest {
server.assertAnalyzeContext(false);
}
+ public void test_scan_source() throws Exception {
+ assertTrackedLibraryFiles(server);
+ server.scan(simpleMoneySrcFile, null);
+ server.start();
+ listener.waitForIdle(1, FIVE_MINUTES_MS);
+ assertTrackedLibraryFiles(server, simpleMoneySrcFile);
+ server.assertAnalyzeContext(true);
+ }
+
+ public void test_scan_sourceThenLibrary() throws Exception {
+ test_scan_source();
+ server.resetAnalyzeContext();
+ server.scan(moneyLibFile, null);
+ listener.waitForIdle(2, FIVE_MINUTES_MS);
+ assertTrackedLibraryFiles(server, moneyLibFile);
+ server.assertAnalyzeContext(true);
+ }
+
public void test_scanContent_import() throws Exception {
PrintStringWriter writer = new PrintStringWriter();
writer.println("import 'foo';");

Powered by Google App Engine
This is Rietveld 408576698