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

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

Issue 280873002: Fix for issue 16423 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Missed issue number Created 6 years, 7 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/CompileTimeErrorCodeTest.java
diff --git a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java
index 7639fbc7375b1d8bb08b33b37a94289a2490da89..6ca2354d997289fe2924ab3100d55578a65b5a26 100644
--- a/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java
+++ b/editor/tools/plugins/com.google.dart.engine_test/src/com/google/dart/engine/resolver/CompileTimeErrorCodeTest.java
@@ -558,7 +558,11 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase {
public void test_constEvalTypeBool_binary_leftTrue() throws Exception {
Source source = addSource("const C = (true || 0);");
resolve(source);
- assertErrors(source, CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL, HintCode.DEAD_CODE);
+ assertErrors(
+ source,
+ CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL,
+ StaticTypeWarningCode.NON_BOOL_OPERAND,
+ HintCode.DEAD_CODE);
verify(source);
}
@@ -3219,7 +3223,10 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase {
" const A(String p) : a = p && true;",
"}"));
resolve(source);
- assertErrors(source, CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL);
+ assertErrors(
+ source,
+ CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL,
+ StaticTypeWarningCode.NON_BOOL_OPERAND);
verify(source);
}
@@ -3230,7 +3237,10 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase {
" const A(String p) : a = true && p;",
"}"));
resolve(source);
- assertErrors(source, CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL);
+ assertErrors(
+ source,
+ CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL,
+ StaticTypeWarningCode.NON_BOOL_OPERAND);
verify(source);
}
@@ -4417,7 +4427,10 @@ public class CompileTimeErrorCodeTest extends ResolverTestCase {
" const A(bool p) : a = " + expr + ";",
"}"));
resolve(source);
- assertErrors(source, CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL);
+ assertErrors(
+ source,
+ CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL,
+ StaticTypeWarningCode.NON_BOOL_OPERAND);
verify(source);
reset();
}

Powered by Google App Engine
This is Rietveld 408576698