k3nsou
15 years agoOccasional Contributor
Launching SOAPUI test with JUNIT : handcheck Fail
Hi, I'm actually working on a project which consist in launching the SOAPUI test using JUNIT.
Using the code I've found on the website I can do it so far, I'm able to execute the test Suite until I reach the call of a Webservice (when the request is send). Then I encountered a handcheck fail certainly due to the usage of certificate (ssl) ...
My Junit test file is as follow, I'm not managing any certifate issue
Running the testCase using directly SOAPUI works because these certificate are configured in the soapui I'm using but I don't know how.
I've found different configuration file in this soapui configuration : certificate, KeyStore for the client and server
I guess I'll have to use these file in order to make it work, the problem is that I don't know how to use them ... Does someone have an idea concerning my problem ?
p.s : As I'm running the test using Junit, and as it's modifying some informations in the project which I need to save for futures runs, I'm wondering if there is a way to tell soapui to save the project at the end of the running of a testcase (using groovy script for example). When I'm launching the test with SOAPUI I have to click on file > save project or else the data won't be updated and so future run won't work properly.
Thanks !
Using the code I've found on the website I can do it so far, I'm able to execute the test Suite until I reach the call of a Webservice (when the request is send). Then I encountered a handcheck fail certainly due to the usage of certificate (ssl) ...
My Junit test file is as follow, I'm not managing any certifate issue
WsdlProject project = new WsdlProject( "D:\\Test-simu-auto-soapui-project.xml" );
TestSuite testSuite = project.getTestSuiteByName( "testsuite" );
TestCase testCase = testSuite.getTestCaseByName( "testcase" );
final TestRunner runner = testCase.run(new PropertiesMap(),false);
Running the testCase using directly SOAPUI works because these certificate are configured in the soapui I'm using but I don't know how.
I've found different configuration file in this soapui configuration : certificate, KeyStore for the client and server
I guess I'll have to use these file in order to make it work, the problem is that I don't know how to use them ... Does someone have an idea concerning my problem ?
p.s : As I'm running the test using Junit, and as it's modifying some informations in the project which I need to save for futures runs, I'm wondering if there is a way to tell soapui to save the project at the end of the running of a testcase (using groovy script for example). When I'm launching the test with SOAPUI I have to click on file > save project or else the data won't be updated and so future run won't work properly.
Thanks !