Web services testing
Web services testing
We're already using Ranorex to test out native windows and web applications, but what support is there for webservice testing, please? We provide a number of webservice links via a .asmx page, and we'd like to automate some tests for them.
David Allsopp,
Test Automation Engineer, Mitrefinch Ltd.
Test Automation Engineer, Mitrefinch Ltd.
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Web services testing
Because Ranorex is a GUI test framework, there is no testing support for webservices per se.
However, Ranorex Studio supports adding web references (Project->References->Add web reference)
which allows direct access to web services in your test scripts. This can be used, for example,
to make web service calls within User Code actions in Recorder.
Michael
Ranorex Team
However, Ranorex Studio supports adding web references (Project->References->Add web reference)
which allows direct access to web services in your test scripts. This can be used, for example,
to make web service calls within User Code actions in Recorder.
Michael
Ranorex Team
Re: Web services testing
OK, I've had a search through the help and around the Ranorex site, and I can't find anything...
So, let's assume I know nothing about web references in Ranorex (this is a very good assumption). How do I go about calling the service? Does it appear as some kind of function call? I can do the 'Add web reference' thing, and the 'Available web services' tab shows the services I expect to see. If I want to use, say, the 'WebServerTime' service to ask the time, what sort of code is it, please? And do you have any examples or stubs to get me started?
I have added this service, and I now get a 'Web References' item in the 'References' tree in Studio, showing a .map, a .disco, and a .wsdl file.
Thanks in advance.
So, let's assume I know nothing about web references in Ranorex (this is a very good assumption). How do I go about calling the service? Does it appear as some kind of function call? I can do the 'Add web reference' thing, and the 'Available web services' tab shows the services I expect to see. If I want to use, say, the 'WebServerTime' service to ask the time, what sort of code is it, please? And do you have any examples or stubs to get me started?
I have added this service, and I now get a 'Web References' item in the 'References' tree in Studio, showing a .map, a .disco, and a .wsdl file.
Thanks in advance.
David Allsopp,
Test Automation Engineer, Mitrefinch Ltd.
Test Automation Engineer, Mitrefinch Ltd.
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Web services testing
There is no documentation for web services in Ranorex because they are standard functionality of the .NET framework and not part of Ranorex. (But they can be used in Ranorex Studio like everything else in the .NET framework)
So if you have your "WebServerTime" web service, add a web reference by using the web service URL of your web service.
When adding, it is probably best to set the namespace to the same namespace as your test script.
(the name of the webservice class itself is determined by the WSDL, not the reference name)
Then you can just call methods on the web service in your test script (or recorder user code actions), e.g.
Michael
Ranorex Team
So if you have your "WebServerTime" web service, add a web reference by using the web service URL of your web service.
When adding, it is probably best to set the namespace to the same namespace as your test script.
(the name of the webservice class itself is determined by the WSDL, not the reference name)
Then you can just call methods on the web service in your test script (or recorder user code actions), e.g.
WebServerTime timeService = new WebServerTime(); // assuming there is a "GetTime" method in your webservice DateTime myTime = timeService.GetTime();Hope this helps,
Michael
Ranorex Team
Re: Web services testing
OK, good, that's beginning to make sense now. A further look at the Web Reference shows a generated .cs file that seems to contain class definitions for an interface. I'm sure I can get the webservice developers to give me a quick tutorial on the rest.
Thanks
Thanks
David Allsopp,
Test Automation Engineer, Mitrefinch Ltd.
Test Automation Engineer, Mitrefinch Ltd.
Re: Web services testing
Hi,
I am in the process of evaluating Ranorex using the latest free trail download version(3.2.1). As part of evaluation test suite, I wanted to carry webservice testing. As per this forum, But I couldn't see 'References > Add web reference’ under 'Project' menu in my Ranorex Studio, instead I could see only 'Project > Add Reference'.
Please help me my studio didn't show this option. Appreciate your help on this.
I am in the process of evaluating Ranorex using the latest free trail download version(3.2.1). As part of evaluation test suite, I wanted to carry webservice testing. As per this forum, But I couldn't see 'References > Add web reference’ under 'Project' menu in my Ranorex Studio, instead I could see only 'Project > Add Reference'.
Please help me my studio didn't show this option. Appreciate your help on this.
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Web services testing
If you right click on the references folder of your project, a context menu with "Add Ref. and Add Web Ref." should appear.surya wrote:But I couldn't see 'References > Add web reference’ under 'Project' menu in my Ranorex Studio, instead I could see only 'Project > Add Reference'.
Regards,
Peter
Ranorex Team
Re: Web services testing
Thanks much for your quick support. Now I can add my web reference.