Class SpockTransform

java.lang.Object
org.spockframework.compiler.SpockTransform
All Implemented Interfaces:
org.codehaus.groovy.transform.ASTTransformation

public class SpockTransform extends Object implements org.codehaus.groovy.transform.ASTTransformation
AST transformation for rewriting Spock specifications. Runs after phase SEMANTIC_ANALYSIS, which means that the AST is semantically accurate and already decorated with reflection information. On the flip side, because types and variables have already been resolved, program elements like import statements and variable definitions can no longer be manipulated at will.
Author:
Peter Niederwieser
  • Constructor Details

    • SpockTransform

      public SpockTransform()
  • Method Details

    • visit

      public void visit(org.codehaus.groovy.ast.ASTNode[] nodes, org.codehaus.groovy.control.SourceUnit sourceUnit)
      Specified by:
      visit in interface org.codehaus.groovy.transform.ASTTransformation