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

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

Issue 913623002: Partial backport of analyzer async/await fixes to Java. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix status files Created 5 years, 10 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 260e6ce2ba42009ac82188bb809fbf22dd0bff5d..cb87325331f9138d9f531d75e8c9095ed5f40ca5 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
@@ -22,6 +22,19 @@ import com.google.dart.engine.error.StaticWarningCode;
import com.google.dart.engine.source.Source;
public class StaticWarningCodeTest extends ResolverTestCase {
+ public void fail_returnWithoutValue_async() throws Exception {
+ // TODO(paulberry): Some async/await type checking has not yet been fully backported from dart.
+ // See dartbug.com/22252.
+ Source source = addSource(createSource(//
+ "import 'dart:async';",
+ "Future<int> f() async {",
+ " return;",
+ "}"));
+ resolve(source);
+ assertErrors(source, StaticWarningCode.RETURN_WITHOUT_VALUE);
+ verify(source);
+ }
+
public void fail_undefinedGetter() throws Exception {
Source source = addSource(createSource(//
// TODO

Powered by Google App Engine
This is Rietveld 408576698