Skip to content

Commit

Permalink
fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
graemerocher committed Mar 10, 2015
1 parent a79de2d commit 6017486
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -886,8 +886,8 @@ public static AnnotationNode addEnhancedAnnotation(final ClassNode classNode, fi
}
if(grailsVersion != null) {
enhancedAnnotationNode.setMember("version", new ConstantExpression(grailsVersion));
classNode.addAnnotation(enhancedAnnotationNode);
}
classNode.addAnnotation(enhancedAnnotationNode);
} else {
enhancedAnnotationNode = annotations.get(0);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,16 @@ import org.codehaus.groovy.ast.builder.AstBuilder
*/
class GrailsASTUtilsTests extends GroovyTestCase {

@Override
protected void setUp() throws Exception {
System.setProperty("grails.version", "3.0.0")
}

@Override
protected void tearDown() throws Exception {
System.setProperty("grails.version", "")
}

void testGetFurthestParent() {
def fooNode = new ClassNode(Foo)
def barNode = new ClassNode(Bar)
Expand Down

0 comments on commit 6017486

Please sign in to comment.