Testing using Java

Currently the abs-maven-plugin provide goal 'javatest' to support execution of ABS unit tests (test code resides at $project.basedir/src/test/abs by default) in Java and interpreting the Java execution output.

To run ABSUnit test in Java from ABS in a ABS Maven project, include the following plugin declaration inside the <build><plugins>...</plugins></build> section of the pom.xml

        ... (see optional configuration for detail) ...

Optional configuration goal javatest

  • absTestFolder, ABS test folder, default is $project.basedir/src/test/abs
  • absJavaBackendTestTargetFolder, Generated Java folder, default is $project.basedir/target/abs/gen/test
  • generateRunner, whether to generate ABSUnit test runner (.abs file containing a main block that executes all specified ABSUnit tests concurrently.
  • absTestRunnerFile, the file to which the generated ABSUnit test runner is written, default is $project.basedir/target/abs/gen/abs/runner.abs
  • productName, build given product by applying deltas (productName is a string that is the qualified product ID)

To test the source of the ABS Maven project, invoke the 'test' goal

mvn test