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

Unified Diff: pkg/analysis_server/test/edit/refactoring_test.dart

Issue 547343004: Send feedback for the INLINE_LOCAL_VARIABLE refactoring. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 3 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/analysis_server/test/edit/refactoring_test.dart
diff --git a/pkg/analysis_server/test/edit/refactoring_test.dart b/pkg/analysis_server/test/edit/refactoring_test.dart
index f46ef7d104bde12cf76f71cdedbd04ad4b15a417..abd5ba00e7b3be02ae69e9ff96864c637b7a40e8 100644
--- a/pkg/analysis_server/test/edit/refactoring_test.dart
+++ b/pkg/analysis_server/test/edit/refactoring_test.dart
@@ -538,6 +538,23 @@ main() {
''');
}
+ test_feedback() {
+ addTestFile('''
+main() {
+ int test = 42;
+ print(test);
+ print(test);
+}
+''');
+ return getRefactoringResult(() {
+ return _sendInlineRequest('test =');
+ }).then((result) {
+ InlineLocalVariableFeedback feedback = result.feedback;
+ expect(feedback.name, 'test');
+ expect(feedback.occurrences, 2);
+ });
+ }
+
test_init_fatalError_notVariable() {
addTestFile('main() {}');
return getRefactoringResult(() {

Powered by Google App Engine
This is Rietveld 408576698