Forum Discussion

pablofuentesbod's avatar
pablofuentesbod
Occasional Contributor
8 years ago

Transfer property value to request header in next step.

Hi all,

 

I'm trying to transfer one property from one test step response to next step request.

 

I have managed to extract the property in a property called myproperty but now I need to use this property in an authentication header but using $myproperty in header value the value is not correctly set during testing.

 

please can you help me to set the header with the property value.

 

thanks in advance, Pablo.

 

 

 

 

  • nmrao's avatar
    nmrao
    8 years ago

    Hmm, really frustrating for both.

     

    Step1:

     

    Select test case name, and select custom tab and add property as mentioned and leave value blank (a Property Transfer step is going to write value for this )

     

    Step 2 : Go to Property transfer step, make the changes as suggested in the image i.e., Select the test case for the target drop down and Select the Property name

     

     

    Then remove the tem_property test step

     

    Step 3:

     

     

     

     

  • nmrao's avatar
    nmrao
    Champion Level 3

    Not sure doing it thru Property Transfer. It can be done using Script Assertion.

     

    If you provide the response of the first request step, and which value needs to be set as header, that would be helpful to offer any help.

    • pablofuentesbod's avatar
      pablofuentesbod
      Occasional Contributor

      Hi rao,

       

      thanks for the update.

       

      I have never used scripts in soap iu .. planning to do using gui as relly straight forward but it in my case it does not work ... the authetification header is not replaced with the property value.

       

      I'm trying to set the authetification header with the vakue if the property / response tag.

       

      thanks for your help.

       

      best regards, Pablo.

       

      • nmrao's avatar
        nmrao
        Champion Level 3
        Hmm.. there seem to be otherway without script too.

        Transfer the property to test case level, say DYNAMIC_AUTH as property name and store the value.

        In the next request, add header with required header name and value as ${#TestCase#DYNAMIC_AUTH}

        Hope the above should help.