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

Unified Diff: pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart

Issue 2614033003: Make subclasses of AbstractContextTest asynchronous. (Closed)
Patch Set: Created 3 years, 11 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/services/refactoring/convert_method_to_getter_test.dart
diff --git a/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart b/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
index 30bbb5b529636637687bc7d627c6d07b88211eb9..4bc00e4d6d3c5d2fcf3d2e1d5898dc64c3c9fc76 100644
--- a/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
+++ b/pkg/analysis_server/test/services/refactoring/convert_method_to_getter_test.dart
@@ -25,8 +25,8 @@ main() {
class ConvertMethodToGetterTest extends RefactoringTest {
ConvertMethodToGetterRefactoring refactoring;
- test_change_function() {
- indexTestUnit('''
+ test_change_function() async {
+ await indexTestUnit('''
int test() => 42;
main() {
var a = test();
@@ -44,8 +44,8 @@ main() {
''');
}
- test_change_method() {
- indexTestUnit('''
+ test_change_method() async {
+ await indexTestUnit('''
class A {
int test() => 1;
}
@@ -89,15 +89,15 @@ main(A a, B b, C c, D d) {
''');
}
- test_change_multipleFiles() {
- indexUnit(
+ test_change_multipleFiles() async {
+ await indexUnit(
'/other.dart',
r'''
class A {
int test() => 1;
}
''');
- indexTestUnit('''
+ await indexTestUnit('''
import 'other.dart';
class B extends A {
int test() => 2;
@@ -121,8 +121,8 @@ main(A a, B b) {
''');
}
- test_checkInitialConditions_alreadyGetter() {
- indexTestUnit('''
+ test_checkInitialConditions_alreadyGetter() async {
+ await indexTestUnit('''
int get test => 42;
main() {
var a = test;
@@ -136,8 +136,8 @@ main() {
'Only class methods or top-level functions can be converted to getters.');
}
- test_checkInitialConditions_hasParameters() {
- indexTestUnit('''
+ test_checkInitialConditions_hasParameters() async {
+ await indexTestUnit('''
int test(x) => x * 2;
main() {
var v = test(1);
@@ -149,8 +149,8 @@ main() {
'Only methods without parameters can be converted to getters.');
}
- test_checkInitialConditions_localFunction() {
- indexTestUnit('''
+ test_checkInitialConditions_localFunction() async {
+ await indexTestUnit('''
main() {
test() {}
var v = test();
@@ -162,8 +162,8 @@ main() {
'Only top-level functions can be converted to getters.');
}
- test_checkInitialConditions_notFunctionOrMethod() {
- indexTestUnit('''
+ test_checkInitialConditions_notFunctionOrMethod() async {
+ await indexTestUnit('''
class A {
A.test();
}
@@ -174,8 +174,8 @@ class A {
'Only class methods or top-level functions can be converted to getters.');
}
- test_checkInitialConditions_returnTypeVoid() {
- indexTestUnit('''
+ test_checkInitialConditions_returnTypeVoid() async {
+ await indexTestUnit('''
void test() {}
''');
_createRefactoring('test');

Powered by Google App Engine
This is Rietveld 408576698