Forum Discussion

Jacob_Hassing's avatar
Jacob_Hassing
Contributor
14 years ago

set endpoint when run from commandline does not work for me

i have 2 wsdl's which i call in my test suite.
when i run from gui, i set endpoint for all requests on each wsdl manually.

when i run from commandLine i start up testrunner.bat with -e switch to specify endpoint for wsdl1
the place where i call service from wsdl2 i have a groovy script that sets the endpoint for step like this:
"  testRunner.testCase.testSteps["testcasename"].getTestRequest().setEndpoint(ENDPOINT) "

but the teststep fails because it uses the global endpoint set when i start testrunner.bat, so appearrently the endpoint is not overwritten by my groovy script ??
any idea why ??

1 Reply

  • SmartBear_Suppo's avatar
    SmartBear_Suppo
    SmartBear Alumni (Retired)
    Hi,

    yes.. this is how the global override works, ie it sets the endpoint before submitting the request, which is after your script has executed. If you want to work around this you will probably need to use property-expansion in your endpoint referring to a project property holding the default endpoint, which can be overriden with the -P=value flag..

    does that help?

    regards!

    /Ole
    eviware.com