opengeospatial / teamengine

TEAM Engine (Test, Evaluation, And Measurement Engine) is an engine for testing web services and other resources written in JAVA. It executes test scripts written in Compliance Test Language (CTL), TestNG and other languages. It is lightweight and easy to run as a command line or to setup as a service. It can be used to test any type of service or encoding. It is also the official tool used by the Open Geospatial Consortium (OGC) for compliance testing.
Apache License 2.0
45 stars 41 forks source link

NullPointerException when running from command line #487

Closed bpross-52n closed 2 years ago

bpross-52n commented 2 years ago

Describe the bug When running test suites (e.g. ets-wfs02) from the command line and adding <entry key="acceptMediaType">application/zip</entry> to the test-run-props.xml to generate HTML reports, a NullPointerException happens in the HTMLReporter class. This happens because it is tried to copy resources from a jar file to the file system, see here.

To Reproduce Steps to reproduce the behavior:

  1. Run a test suite (e.g. ets-wfs02) from the command line, add <entry key="acceptMediaType">application/zip</entry> to the test-run-props.xml
  2. HTML reports are generated, but not zipped, a NullPointerException happens

Expected behavior HTML reports are generated and zipped, no exception happens.

Additional context See also this issue. The HTML generation works when running the test suite from within a servlet container, as the resources folder exists physically in the TEAM Engine webapp folder.