Forum Discussion

_ivanovich_'s avatar
_ivanovich_
Frequent Contributor
5 years ago

What is testPassErrorsSuccess property?

Hi,

in my soapui project, i added a groovy step where i try to get the test status.

try{
def A = "Hello"
assert slurper.data.DOC.ACT[0].toString() == A
testRunner.testCase.testSuite.project.setPropertyValue("statusPass_A",'TEST PASS')
catch (AssertionError e){
testRunner.testCase.testSuite.project.setPropertyValue("statusFail_A",'TEST FAIL')
log.info context.getTestRunner().fail("ERROR")
}
}

 

The result is:

when the test pass, it creates the property "statusPass_A" with "TEST PASS"

But it creates also another property named testPassErrorsSuccess with "TEST PASS"

 

Where does it come from?

Is it soapui inbuilt propety?

 Thank you

5 Replies

  • nmrao's avatar
    nmrao
    Champion Level 3
    Not sure of the use case, why is it needed in groovy? Haven't had a chance to see such use case.
    • _ivanovich_'s avatar
      _ivanovich_
      Frequent Contributor

      A json content is retrieved from a talble with a groovy step.

      Then it 's just parsing a json file.

      It asserts some data in json file.

      If the assertion is true it says test pass

      otherwise test failed. that's all.

       

      It's needed in groovy because i generate a pdf report where i can see test status for each test.

      It works well for me.

       

      But i don't understand why sopaui creates a property itself named: testPassErrorsSuccess

      I definitely not create this property. 

      • nmrao's avatar
        nmrao
        Champion Level 3
        Thank for the details.

        If I understand write, instead of jdbc test step, a groovy script test step is retrieving data.
        And where do you have assertion? In the same groovy script?

        Glad to know that you create pdf file for the report. But would be glad if you can share more details on how that is done? Or a sample dummy project do the same can be useful.

        Not sure how you are trying to get the status, probably you may want to take a look at the below thread which was some time ago and see if that is useful.

        https://stackoverflow.com/questions/41700437/creating-a-test-report-from-project-level-tear-down-script