Sending Results to Parasoft Development Testing Platform (DTP) Using cURL

David ChaconDavid Chacon Posts: 7 admin

Use curl or a similar utility to upload report.xml file to the DTP Data Collector for example:

curl --user admin:admin -F file=@ https://machine.parasoft.

Note that DTP currently limits the size of the XML reports it will accept; that limit is currently 512MB.
When a report over 512MB is sent to DTP, you will receive an error stating that the report is too large.
If this occurs, perform the following steps:
1. Zip the report and send DTP the zipped report (instead of the original report).
2. Modify the com.parasoft.sdm.api.rawstorage.datacollector.uploadMaxSize DTP setting
that controls what size reports are accepted by the data collector. You can modify the
Data Collector JVM argument -Dcom.parasoft.sdm.api.rawstorage.datacollector.
uploadMaxSize=512. Or, for Linux installations, modify the following string in the /bin/variables

**For use of Code Coverage Engine with SOATest, the DTP Engine will be required. **

With the proper configuration, SOAtest will collect application coverage during test execution. To configure and execute SOAtest for application coverage data collection:

  1. Configure a SOAtest Test Configuration to collect application coverage data as follows:
    a. Open the Test Configuration that you want to collect application coverage data.
    b. Open the Execution> Application Coverage tab.
    c. Enable the Collect application coverage option.
    d. Under Coverage agent host, specify the host name or IP address of the machine where the coverage agent resides.
    e. Under Coverage agent port, specify the coverage agent’s port. The default is 8050. You can click Test Connection to check if your settings are working properly.
    f. If you want test failures reported when the coverage agent connection fails, check. Report coverage agent connection failures as test failures. Otherwise, connection problems will be reported to the console, but will not cause the test to fail.
    g. Check Retrieve coverage data, then use Coverage data storage directory to indicate where you want the dynamic coverage data stored. You do not need to enable this option if the coverage agent is running on the build machine where static coverage was generated (since, in this case, both the static and runtime data can be published to DTP directly from the build machine).
    h. If you want the coverage data on the AUT (application under test) deleted as soon as SOAtest retrieves it, also check Delete coverage data on retrieval. We recommend enabling this option in order to prevent the buildup of data files on the machine where the coverage agent is located.
    i. Apply the Test Configuration changes.

  2. Configure a SOAtest localsettings file that sets:
    • The build id ( based on how you want to correlate coverage results. If you want to merge these coverage results with those from other types of testing—such as unit testing and manual testing of the same application—they must all use the same build id. The build id set here must match the one that will be set on the DTP engine when collecting the static and dynamic coverage files and uploading the coverage data.
    • The project (general.project). This value must match the dtp.project value that will be set on the DTP engine when collecting the static and dynamic coverage files and uploading the coverage data.

  3. Run a test in command line mode using the Test Configuration and localsettings file that were previously configured. This test should be part of an automated process.

Uploading Combined Coverage Reports

*Use the DTP Engine to generate a coverage.xml file and upload it to DTP as described in the
DTP Engines documentation. Remember that SOAtest stores dynamic coverage data in the
location specified in the SOAtest Test Configuration’s Coverage data storage field.

Note:Before you generate the coverage.xml file, be sure that the build id and project values set from the DTP Engine match those set in the SOAtest localsettings file.
(instructions on coverage.xml can be found starting pg 49 of the DTP Engines for Java User's Guide)

Sign In or Register to comment.