Service Virtualization

  • 1.  Can i store step result (Pass/Fail) in a parameter

    Posted Jul 22, 2016 05:05 PM

    In my test i am sending the result of step in subprocess as Pass or Fail. Is there a default lisa parameter that stores whether a step passed of failed. At present i have the below flow.

     

    1. Execute step

    2. If assertion of step 1 passed set Paramater Verdict= Pass

    3. If assertion of Step 1 failed set Paramater Verdict= Fail

    4. Execute Subprocess with Verdict as input

     

    i am trying to see if there is a default parameter that automatically stores the step result and i can pass that to subprocess directly



  • 2.  Re: Can i store step result (Pass/Fail) in a parameter

    Posted Jul 27, 2016 10:00 AM

    looking at my VSM, which uses scripts.  each step sets some properties

     

    lisa.stepname.rsp = the step response



  • 3.  Re: Can i store step result (Pass/Fail) in a parameter

    Posted Jul 28, 2016 10:35 AM

    Thanks i am storing step response already i am looking for more for test result. This is the current flow i have i am trying to remove step 2 and 3 and accomplish it somehow in Step 1.

     

     

    1. Execute step

    2. If assertion of step 1 passed set Paramater Verdict= Pass

    3. If assertion of Step 1 failed set Paramater Verdict= Fail

    4. Execute Subprocess with Verdict as input



  • 4.  Re: Can i store step result (Pass/Fail) in a parameter

    Broadcom Employee
    Posted Jul 28, 2016 10:49 AM

    What kind of assertion are you adding to 1. Execute step?



  • 5.  Re: Can i store step result (Pass/Fail) in a parameter

    Posted Jul 28, 2016 11:01 AM

    Xml xpath assertion ...........  to give more background we maintain test suite in test management tool Rally. ........ so based on the Lisa test we update Rally test case with Pass or Fail. I have a subprocess that updates rally test case.

     

    What i am trying to execute the step and then execute sub process with input parameter pass/fail ......... At present i am able to achieve it using below current flow but its 3 extra steps just to update Rally i am trying to simplify it to 2 steps

    1. Execute Step

    2. Execute Sub  process with input pass/fail based on step 1.

     

    Current Flow

    1. Execute step

    2. If assertion of step 1 passed set Paramater Verdict= Pass

    3. If assertion of Step 1 failed set Paramater Verdict= Fail

    4. Execute Subprocess with Verdict as input



  • 6.  Re: Can i store step result (Pass/Fail) in a parameter
    Best Answer

    Broadcom Employee
    Posted Jul 28, 2016 12:02 PM

    One option you have is to use an XML Xpath filter instead of an assertion using the same Xpath Query as used in the assertion, saving the result in a property Verdict.

     

    Depending on the value returned in the response, the Xpath filter would set Verdict to be either true or false.

    Then you can call your Subprocess after making the change for Pass/Fail to true/false (this will depend on your query)



  • 7.  Re: Can i store step result (Pass/Fail) in a parameter

    Posted Jul 28, 2016 12:09 PM

    Thanks this will work but i guess i was also thinking if i use any other assertion i will run into same ........ so i was hoping that there is direct lisa property that saves whether assertion passed or failed and i can use that ...... to pass to subprocess ......