Start sbt Once - Avoid the Startup Delay for sbt

Just issue the 'sbt' command, then type individual commands at the sbt prompt. This saves the startup time for sbt itself.

Run exactly one Integration test

This sbt command runs exactly one integration test:

daffodil-cli/IntegrationTest/testOnly org.apache.daffodil.parsing.TestCLIparsing -- --tests=test_XXX_CLI_Parsing_SimpleParse_sax

You can use wildcards in the class name to shorten the command line, but this slows down the testing because it has to search for the test. For example: this works, though a bit more slowly:

daffodil-cli/IntegrationTest/testOnly *.TestCLIparsing -- --tests=test_XXX_CLI_Parsing_SimpleParse_sax

To run one regular test change the module from daffodil-cli to the other module, change IntegrationTest to just "Test", and the class and test name for your test.

If you leave off the module, the command will still work, just more slowly, as it must scan all modules to find the test class.

If you have edited Daffodil source code, the above commands will automatically re-stage the jars/binary/scripts so that these tests will work on the modified daffodil. That takes a while because staging is slow.

The entire testOnly command including arguments will need to be enclosed in quotes if you type it as a sbt command on the command line prompt instead of a testOnly command at the sbt prompt:

sbt "daffodil-test/testOnly org.apache.daffodil.section05.facets.TestNulChars"
  • No labels