Forum Discussion
SmartBear_Suppo
16 years agoSmartBear Alumni (Retired)
Hello,
In the upcoming nightly build of soapUI there are some new methods defined for the Attachment object. These are getData and setData which return and take a byte[]. This allows you to modify the attachment data in memory (without changing the file in the filesystem). In groovy you could access this using:
which is both readable and writable. Good luck!
Regards,
Dain
eviware support
In the upcoming nightly build of soapUI there are some new methods defined for the Attachment object. These are getData and setData which return and take a byte[]. This allows you to modify the attachment data in memory (without changing the file in the filesystem). In groovy you could access this using:
testRunner.testCase.testSteps['Your Request Name'].httpRequest.getAttachmentAt(0).data
which is both readable and writable. Good luck!
Regards,
Dain
eviware support
- bkbn169 years agoContributor
I tried this "
testRunner.testCase.testSteps['Your Request Name'].httpRequest.getAttachmentAt(0).data
"
But I am getting error...
java.lang.NullPointerException: Cannot get Property 'httpRequest' on null object. Please help
Related Content
- 6 years ago
- 10 years ago
Recent Discussions
- 15 years ago