Hi McDonald,
That script has got me further. However, i need the name spaces of the nodes being changed, changed as well. This was not straight forward when I tried implementing that functionality.
However, your script did give me ideas. Thanks
I have managed to get functionality required using a hack - now that I know how to set the request object after manipulation is done.
I treat the request as a plain string and call replaceAll.
def request = context.expand( '${updateRequest#Request}' ).toString()
request = request.replaceAll("ns3:valuation", "ns22:data")
def tc = testRunner.testCase;
tc.getTestStepByName('updateRequest').httpRequest.requestContent = request
def result = null //to stop the groovy information pop-up
This will get me over the line. I am aware of the risk of other data being changed as a result, but I am only changing namespace:nodename type combos. So, other data should be relatively safe. Please advise if there is any other risk or problem with doing it this way.
Thanks again, much appreciated,
TestRanger