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

Unified Diff: editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java

Issue 18341022: Report REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 5 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: editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java
diff --git a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java
index 6df94d3076b99ba998e20338b1c405fc18dd7fc8..c81a4641812ec4adcfca777dd5cc1eef0e767dc4 100644
--- a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java
+++ b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/StaticWarningCodeTest.java
@@ -1529,7 +1529,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
" A(int p) {}",
"}",
"class B {",
- " B() = A;",
+ " factory B() = A;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_INVALID_FUNCTION_TYPE);
@@ -1542,7 +1542,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
" A() {}",
"}",
"class B {",
- " B() = A;",
+ " factory B() = A;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_INVALID_RETURN_TYPE);
@@ -1555,7 +1555,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
" A() {}",
"}",
"class B {",
- " B() = A.name;",
+ " factory B() = A.name;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_MISSING_CONSTRUCTOR);
@@ -1567,7 +1567,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
" A.name() {}",
"}",
"class B {",
- " B() = A;",
+ " factory B() = A;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_MISSING_CONSTRUCTOR);
@@ -1577,7 +1577,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
Source source = addSource(createSource(//
"class B {",
" int A;",
- " B() = A;",
+ " factory B() = A;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_NON_CLASS);
@@ -1587,7 +1587,7 @@ public class StaticWarningCodeTest extends ResolverTestCase {
public void test_redirectToNonClass_undefinedIdentifier() throws Exception {
Source source = addSource(createSource(//
"class B {",
- " B() = A;",
+ " factory B() = A;",
"}"));
resolve(source);
assertErrors(StaticWarningCode.REDIRECT_TO_NON_CLASS);

Powered by Google App Engine
This is Rietveld 408576698