Forum Discussion

whitecloud's avatar
whitecloud
Occasional Contributor
13 years ago

can one assertion be inserted to multiple Rest request?

Hi,

I am wondering if the following requirement could be achieved (in open source or pro version)?

There is a project that has many Rest web service request, each web service method has a schema online (http://server/methodName/schema). There is no wadl and service response does not have inferred schema). Currently each rest request has an assertion which has the same groovy script (except schema url) to validate response xml schema.

I would like to remove the repetitive assertion from each request and use the load script of project to insert the validation assertion to each rest request, is that applicable? I could do that with available assertion like
restTestSteps[it].addAssertion(“SOAP Response”)
, but not sure if I could add customized assertion?

Thanks.
No RepliesBe the first to reply