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

Unified Diff: pkg/analyzer/test/src/dart/constant/evaluation_test.dart

Issue 2524903002: Rename AstFactory -> AstTestFactory. (Closed)
Patch Set: Created 4 years, 1 month 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/analyzer/test/src/dart/constant/evaluation_test.dart
diff --git a/pkg/analyzer/test/src/dart/constant/evaluation_test.dart b/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
index 47ed912a3cda1ad2c3199697f6257d9c980a8f67..43dfdf7b21dc033112b4f01fcaf68cdbfb1b69ce 100644
--- a/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
+++ b/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
@@ -17,7 +17,7 @@ import 'package:analyzer/src/generated/engine.dart';
import 'package:analyzer/src/generated/resolver.dart';
import 'package:analyzer/src/generated/source.dart';
import 'package:analyzer/src/generated/source_io.dart';
-import 'package:analyzer/src/generated/testing/ast_factory.dart';
+import 'package:analyzer/src/generated/testing/ast_test_factory.dart';
import 'package:analyzer/src/generated/testing/test_type_provider.dart';
import 'package:analyzer/src/task/dart.dart';
import 'package:path/path.dart';
@@ -1407,10 +1407,10 @@ class A {
@reflectiveTest
class ConstantVisitorTest extends ResolverTestCase {
void test_visitBinaryExpression_questionQuestion_notNull_notNull() {
- Expression left = AstFactory.string2('a');
- Expression right = AstFactory.string2('b');
- Expression expression =
- AstFactory.binaryExpression(left, TokenType.QUESTION_QUESTION, right);
+ Expression left = AstTestFactory.string2('a');
+ Expression right = AstTestFactory.string2('b');
+ Expression expression = AstTestFactory.binaryExpression(
+ left, TokenType.QUESTION_QUESTION, right);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
@@ -1423,10 +1423,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitBinaryExpression_questionQuestion_null_notNull() {
- Expression left = AstFactory.nullLiteral();
- Expression right = AstFactory.string2('b');
- Expression expression =
- AstFactory.binaryExpression(left, TokenType.QUESTION_QUESTION, right);
+ Expression left = AstTestFactory.nullLiteral();
+ Expression right = AstTestFactory.string2('b');
+ Expression expression = AstTestFactory.binaryExpression(
+ left, TokenType.QUESTION_QUESTION, right);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
@@ -1439,10 +1439,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitBinaryExpression_questionQuestion_null_null() {
- Expression left = AstFactory.nullLiteral();
- Expression right = AstFactory.nullLiteral();
- Expression expression =
- AstFactory.binaryExpression(left, TokenType.QUESTION_QUESTION, right);
+ Expression left = AstTestFactory.nullLiteral();
+ Expression right = AstTestFactory.nullLiteral();
+ Expression expression = AstTestFactory.binaryExpression(
+ left, TokenType.QUESTION_QUESTION, right);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
@@ -1454,10 +1454,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitConditionalExpression_false() {
- Expression thenExpression = AstFactory.integer(1);
- Expression elseExpression = AstFactory.integer(0);
- ConditionalExpression expression = AstFactory.conditionalExpression(
- AstFactory.booleanLiteral(false), thenExpression, elseExpression);
+ Expression thenExpression = AstTestFactory.integer(1);
+ Expression elseExpression = AstTestFactory.integer(0);
+ ConditionalExpression expression = AstTestFactory.conditionalExpression(
+ AstTestFactory.booleanLiteral(false), thenExpression, elseExpression);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
new ErrorReporter(errorListener, _dummySource());
@@ -1466,10 +1466,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitConditionalExpression_nonBooleanCondition() {
- Expression thenExpression = AstFactory.integer(1);
- Expression elseExpression = AstFactory.integer(0);
- NullLiteral conditionExpression = AstFactory.nullLiteral();
- ConditionalExpression expression = AstFactory.conditionalExpression(
+ Expression thenExpression = AstTestFactory.integer(1);
+ Expression elseExpression = AstTestFactory.integer(0);
+ NullLiteral conditionExpression = AstTestFactory.nullLiteral();
+ ConditionalExpression expression = AstTestFactory.conditionalExpression(
conditionExpression, thenExpression, elseExpression);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
@@ -1481,10 +1481,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitConditionalExpression_nonConstantElse() {
- Expression thenExpression = AstFactory.integer(1);
- Expression elseExpression = AstFactory.identifier3("x");
- ConditionalExpression expression = AstFactory.conditionalExpression(
- AstFactory.booleanLiteral(true), thenExpression, elseExpression);
+ Expression thenExpression = AstTestFactory.integer(1);
+ Expression elseExpression = AstTestFactory.identifier3("x");
+ ConditionalExpression expression = AstTestFactory.conditionalExpression(
+ AstTestFactory.booleanLiteral(true), thenExpression, elseExpression);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
new ErrorReporter(errorListener, _dummySource());
@@ -1495,10 +1495,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitConditionalExpression_nonConstantThen() {
- Expression thenExpression = AstFactory.identifier3("x");
- Expression elseExpression = AstFactory.integer(0);
- ConditionalExpression expression = AstFactory.conditionalExpression(
- AstFactory.booleanLiteral(true), thenExpression, elseExpression);
+ Expression thenExpression = AstTestFactory.identifier3("x");
+ Expression elseExpression = AstTestFactory.integer(0);
+ ConditionalExpression expression = AstTestFactory.conditionalExpression(
+ AstTestFactory.booleanLiteral(true), thenExpression, elseExpression);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
new ErrorReporter(errorListener, _dummySource());
@@ -1509,10 +1509,10 @@ class ConstantVisitorTest extends ResolverTestCase {
}
void test_visitConditionalExpression_true() {
- Expression thenExpression = AstFactory.integer(1);
- Expression elseExpression = AstFactory.integer(0);
- ConditionalExpression expression = AstFactory.conditionalExpression(
- AstFactory.booleanLiteral(true), thenExpression, elseExpression);
+ Expression thenExpression = AstTestFactory.integer(1);
+ Expression elseExpression = AstTestFactory.integer(0);
+ ConditionalExpression expression = AstTestFactory.conditionalExpression(
+ AstTestFactory.booleanLiteral(true), thenExpression, elseExpression);
GatheringErrorListener errorListener = new GatheringErrorListener();
ErrorReporter errorReporter =
new ErrorReporter(errorListener, _dummySource());
« no previous file with comments | « pkg/analyzer/test/src/dart/ast/utilities_test.dart ('k') | pkg/analyzer/test/src/dart/constant/utilities_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698