Reputation: 69
How to integrate the guidewire G Unit testing utility in Jenkins. I tried to found the relevant doc but no luck.
Upvotes: -1
Views: 186
Reputation: 1088
You can run unit tests through Jenkins by adding a step for unit testing to your pipeline that runs the below command
gwb test
(Windows Server)
or
./gwb test
(Linux server)
This will run all unit tests, which may not be your intention and it may take a large amount of time to run all unit tests depending on your application. To run selective test suites you can use the below command
gwb runSuite -Dsuite=acme.cc.AcmeServerTestSuite -Ddir.results=modules\configuration\build\testresults\
AcmeServerTestSuite
dir.results
is used to specify the directory where unit test results are stored. This file can be saved in an artifactory for consumption by a system that shows test results for each pipeline run.
You can even get metrics like code coverage using Jacoco or a similar plugin, the details of which are documented here (requires login).
Upvotes: 2