Contributions
TestCase Scope VS Mock Scope
I'm passing data from a TestCase to the Mock Server by storing it in a Project Property. This works if I'm running the testcase and the mock server from the SoapUI gui but does not work if the test and the mock server are run from the command line. This kind of makes sense because in the first situation the testcase and the mock server share the scope of the soapui app, in the second situation the testcase and mock server do not share that scope. My thoughts are to simply raise the scope where I store the shared data... e.g. put it in a windows environment variable. I'm still trying to figure the syntax to do this. Does anyone have any other idea's / suggestions? thanks Glenn1.5KViews0likes2CommentsgroovyUtils setPropertyValue... Can I only set a testStep property value?
The docs at http://www.soapui.org/userguide/functional/groovystep.html#soapUI_GroovyUtils say: + setPropertyValue( String testStepName, String propertyName, String value ) : sets the specified property value I want to set a property at a higher scope than the testCase so that the Mock can expand this property. Glenn2.6KViews0likes1CommentIs it really so hard to WRITE context properties?
There seems to be a number of ways to read context properties but the only way to write them is: def testProject = testRunner.testCase.testSuite.project.workspace.getProjectByName("myProject") testProject.properties["myProperty"].value = "myValue" and getProjectByName stops me running from the command line. I'm hoping someone's gonna say 'don't be so dumb! you just do it like this'. Glenn1.3KViews0likes1Comment