Skip to content

Commit

Permalink
Added generics statements on constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
gastaldi committed Aug 6, 2013
1 parent 531893d commit dfced4a
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ public void testSupportsGenericsSource() throws Exception {
JavaSource<?> source = JavaParser.parse("public class Test{public void test() {java.util.List<String> s = new java.util.ArrayList<String>(); for (String item : s){}}}");
Assert.assertFalse(source.hasSyntaxErrors());
}

@Test
public void testSupportsGenericsSourceFromConstructor() throws Exception {
JavaSource<?> source = JavaParser.parse("public class Test{public Test() {java.util.List<String> s = new java.util.ArrayList<String>(); for (String item : s){}}}");
Assert.assertFalse(source.hasSyntaxErrors());
}

@Test
public void testSupportsGenericsSourceFromMethod() throws Exception {
JavaClass source = JavaParser.parse(JavaClass.class,"public class Test{}");
Expand Down

0 comments on commit dfced4a

Please sign in to comment.