Forum Discussion

MRtai2's avatar
MRtai2
Occasional Contributor
14 years ago

Accessing TestRequest Properties through groovy

Can anyone shed light on how to access 'TestRequest Properties' for a RequestStep via code? I'm only able to find info on how to add properties which are for 'Test Properties'.

Ie. the below adds properties to the 'Test Properties' tab. But I would like to change some properties in the 'TestRequest Properties' tab (mainly WSS-Password Type).



tStep.setPropertyValue("Password", "password");
tStep.setPropertyValue("Username","user");
tStep.setPropertyValue("WSS-Password Type", "PasswordText");


tStep.setPropertyValue("WSS-Password Type", "PasswordText") - does nothing

Thanks!

1 Reply

  • MRtai2's avatar
    MRtai2
    Occasional Contributor
    All I needed was a break



    WsdlTestRequestStep tStep = requests.get(i);
    tStep.getHttpRequest().setWssPasswordType("PasswordText");