pavlobaron / robotframework-soapuilibrary

SoapUI test library for the Robot Framework
Apache License 2.0
30 stars 21 forks source link

mock wsdl and rest web services #2

Open poliarush opened 12 years ago

poliarush commented 12 years ago

are going to implement such functionality in your library?

pavlobaron commented 12 years ago

do you mean this: http://www.soapui.org/Service-Mocking/mocking-soap-services.html and http://www.soapui.org/apidocs/com/eviware/soapui/model/mock/MockService.html ?

Seems to be possible to access it through the API, though I didn't work with it yet. But it should be possible. Do you have a working example in a project file and could you gist it please so I can have a look?

poliarush commented 12 years ago

yes

https://docs.google.com/file/d/0B3bcyhcYBd3nUkJVUFNSU1BTOXlnOVl1T0ozX1VlZw/edit

poliarush commented 12 years ago

i got code that run mock service from soapui

def project = context.testCase.getTestSuite().getProject(); def mockService = project.getMockServiceByName("WorkScheduleServiceMock"); mockService.start();

pavlobaron commented 12 years ago

done. see examples/mock

poliarush commented 12 years ago

super fast, thanks

i will check today's evening

poliarush commented 12 years ago

i modified a bit run.bat to

set SOAPUI_HOME="c:\Program Files (x86)\SmartBear\soapUI-4.0.1"

jybot --pythonpath %SOAPUI_HOME%/bin/soapui-4.0.1.jar:%SOAPUI_HOME%/lib/STAR.jar --escape star:STAR --variable PRJ:tempconvert-soapui-project.xml --variable SUITE:suite --variable CASE:case --variable MOCK:mock test.txt

run it and get following issue http://pastebin.com/PtXR3c21

looking for suggestions!

pavlobaron commented 12 years ago

That's plenty of error text...

As far as I can see, the whole problem is around "java.lang.ClassCastException: com.eviware.soapui.config.impl.InterfaceConfigImpl cannot be cast to com.eviware.soapui. config.WsdlInterfaceConfig". But I have no idea, what it is. Is it any related to SoapUI running on Windows? Different versions? I must admit, I only tested on Ubuntu.

Can anyone confirm the error?

poliarush commented 12 years ago

I tested on

and can reproduce issue