Forum Discussion
bmgriner
14 years agoFrequent Contributor
Yes, that is what I want. Here is some more description.
I have a script that looks like this that I run against every test step in a few test cases:
If I have an environment set other than "Default", then the above code changes that Environment's default endpoint, and every test case after the above code is run uses the new endpoint instead.
I want the ability to have one or more test cases run against a non-standard endpoint without breaking the rest of my test cases.
I have a script that looks like this that I run against every test step in a few test cases:
def static setTestStepEndpoint(testStep, log, String endpoint) {
if (testStep instanceof RestTestRequestStep || testStep instanceof WsdlTestRequestStep) {
testStep.getTestRequest().setEndpoint(endpoint)
log.info("Endpoint for the test step + [" + testStep.getLabel() + "] is now [" + testStep.getTestRequest().getEndpoint() + "]")
}
}If I have an environment set other than "Default", then the above code changes that Environment's default endpoint, and every test case after the above code is run uses the new endpoint instead.
I want the ability to have one or more test cases run against a non-standard endpoint without breaking the rest of my test cases.