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

Unified Diff: pkg/analysis_server/test/services/correction/fix_test.dart

Issue 636293002: Search for function to import even when reported as UNDEFINED_METHOD. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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
« no previous file with comments | « pkg/analysis_server/lib/src/services/correction/fix_internal.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/test/services/correction/fix_test.dart
diff --git a/pkg/analysis_server/test/services/correction/fix_test.dart b/pkg/analysis_server/test/services/correction/fix_test.dart
index 766afc02ffda23d99d79666fc9f3dc23cd49a64f..9af602c2d9f443e795616c033243442c609844c4 100644
--- a/pkg/analysis_server/test/services/correction/fix_test.dart
+++ b/pkg/analysis_server/test/services/correction/fix_test.dart
@@ -1227,6 +1227,30 @@ main() {
''');
}
+ void test_importLibraryProject_withFunction_unresolvedMethod() {
+ addSource('/lib.dart', '''
+library lib;
+myFunction() {}
+''');
+ _indexTestUnit('''
+class A {
+ main() {
+ myFunction();
+ }
+}
+''');
+ performAllAnalysisTasks();
+ assertHasFix(FixKind.IMPORT_LIBRARY_PROJECT, '''
+import 'lib.dart';
+
+class A {
+ main() {
+ myFunction();
+ }
+}
+''');
+ }
+
void test_importLibraryProject_withTopLevelVariable() {
addSource('/lib.dart', '''
library lib;
« no previous file with comments | « pkg/analysis_server/lib/src/services/correction/fix_internal.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698