Contributions
How to fetch the output or Error message of a Shell script through groovy on remote server.
Hi, Iwant to execute a shell script on a remote server and want to fetch the output/error message of the shell script. Can anyone provide some solution to me on this? Thanks in advance.Solved7 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.3KViews0likes1CommentRe: Is there any way to get rest resource of a rest step through Groovy.
Hi, No problem, ifrequestFilter.filterRequest runs after each test cases. And I would like to do my activity before the step execute sorequestFilter.filterRequest Is it the correct one to do that ? If you can provide me the code then that will really helpful .Btw how can we see the logs of a Event Handler ?7 years agoPlace ReadyAPI QuestionsReadyAPI Questions5.3KViews0likes2CommentsRe: Is there any way to get rest resource of a rest step through Groovy.
Hi, Thanks for your response I tried this "log.infocontext.getProperty("requestUri")"but it returns Null as output. If I replace Endpoint in place ofrequestUri then it returns the IP & PORT but I need the information which is added in Resource . IsrequestUri is the correct key to fetch resource URL ? Problem here is that we are able to fetch any information of a rest step which are added in Custom property but not those which are coming in REST Request Property.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions5.4KViews0likes4CommentsRe: soap request doesn't replace variable
Can you try one thing ? Inplace of putting all those directly in the Soap request. 1-Just add a data generator before the Soaprequest. 2-Add a Template in the data generator. 3-Addthis in the Template. <ADD_SOC_REQUEST> <MSISDN>${context.get('msisdnList').last()}</MSISDN> <SOC>SMPGL2</SOC> </ADD_SOC_REQUEST> 4-Run the data generator . 5-Now call & add the template key in the Soap request & run the step. Hope it will work .1.7KViews0likes2CommentsIs there any way to get rest resource of a rest step through Groovy.
Hi, I am looking to fetch resource part of a rest step through . which we provide in the resource section . Note-: def testStepNameNew=testRunner.testCase.getTestStepByName("Login") def endPointInfo=testStepNameNew.getProperty("Endpoint").getValue() log.info endPointInfo op-: http://IP:PORT But I am looking for the resource part . Any kind of help will be really appreciated !!! ThanksSolved7 years agoPlace ReadyAPI QuestionsReadyAPI Questions5.5KViews0likes7CommentsRe: How to avoid Maven build failed in cases of Soapui Testcases failure
Hi, While executing your pom file try to use this command cleanverify-fn-f-Dmaven.test.failure.ignore=true Hope this will help you,please let me know you face any issue.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.2KViews1like0CommentsRe: How to take a value from the request & save as a global property when the response is positive
1-Run your rest step once with positive data 2-Add a groovy script in your test case . 3-Right click and selectGet Data. 3-Go to your rest case and select the test step 4- Add harResponse. 5- InharResponse, there will be #status# which return a code . It returns 2 different code,one for positive & one for negative (please check once with your data) 6-Select#status#fromharResponse . (This will give you idea whether your test step is passed or failed) Example def harResponse = context.expand( '${#[TestSuite#TestCase#RestStep]#HarResponse#$[\'headers\'][0][\'value\']}' ) let suppose expected#status#="HTTP/1.1 201" Solution_1 After that use this code if(harResponse_StatusCode.equals(harResponse)) { //get your data from rest step in the same way as above mention(this time select response in place of harResponse) Example def getResponseInfo = context.expand( '${#[TestSuite#TestCase#RestStep]#Response#$[\'responseInfo\']}' ) def globalProperties=com.eviware.soapui.SoapUI.globalProperties globalProperties.setPropertyValue("SetGlobalpropertyName", "$getResponseInfo") } Solution_2 try{ //get your data from rest step in the same way as above mention(this time selectresponsein place ofharResponse) Example def getResponseInfo = context.expand( '${#[TestSuite#TestCase#RestStep]#Response#$[\'responseInfo\']}' ) def globalProperties=com.eviware.soapui.SoapUI.globalProperties globalProperties.setPropertyValue("SetGlobalpropertyName", "$getResponseInfo") } catch(Exception) { log.error " rest step is failed " } Hope this will help you,let me know if you face any problem.7 years agoPlace ReadyAPI QuestionsReadyAPI Questions1.7KViews1like0Comments