header
header
Main Menu
Home
Eviware Store
Downloads
Products
News
Forum
Eviware Blog
Search
FAQs
Customer Area
Support
Documentation
Tutorials
CookBook
Downloads
Forum
Login Form
Welcome, Guest. Please login or register.
November 22, 2008, 02:48:23 pm
Username: Password:
Login with username, password and session length

Forgot your password?
 
Latest posts of: Tareque
Welcome, Guest. Please login or register.
November 22, 2008, 02:48:23 pm
Home Help Search Login Register
News: The Forums are up! Welcome to eviware.

  Show Posts
Pages: [1] 2
1  soapUI / soapUI / Re: Connection String for Oracle datasource on: March 12, 2008, 02:40:56 pm
Hi Ole,
The screen shot is attached. The driver class that i am using is
oracle.jdbc.driver.OracleDriver i also tried
oracle.jdbc.pool.OracleDataSource but that is giving me no suitable driver class found error.
Regards
2  soapUI / soapUI / Re: Connection String for Oracle datasource on: March 11, 2008, 07:44:29 pm
Hi Ole,
From an earlier post i found that we have to specify the url in the following format
jdbc:oracle:thin:scott/tiger@10.185.13.128:1521:ora9i


I have done the same now in my DataSource
jdbc:oracle:thin:FAST/FASTER@10.185.13.128:1521:dtwd
but i am getting IO error
Tue Mar 11 14:36:49 EDT 2008:ERROR:java.sql.SQLException: Io exception: The Network Adapter could not establish the connection

This is not a network issue as I am able to access the DB using a groovy script.
def sql = groovy.sql.Sql.newInstance("jdbc:oracle:thin:@10.185.13.128:1571:dtwd", "FAST", "FASTER", "oracle.jdbc.pool.OracleDataSource")
Can you please tell me how i can use this sql connection that I have created  in the groovy script in the DataSource Step.
3  soapUI / soapUI / Connection String for Oracle datasource on: March 11, 2008, 03:33:49 pm
Hi,
I am trying to create an Oracle datasource specifying the following
DriverClass
oracle.jdbc.pool.OracleDataSource
ConnectionString
jdbc:oracle:thin:@localhost:1571:dtwd;user=FAST;password=FASTER;

It fails giving SQLEXception invalid arguments in call.
I think that the ConnectionString format which i have given is incorrect, can you please provide the correct format for the ConnectionString for Oracle.
Thanks
Tareque
4  soapUI / soapUI / Invoking TestRunner from web application on: February 14, 2008, 04:18:19 pm
Hi,
I am creating a web application which will allow users to execute testRunner from a browser. Is there any way this can be achieved? Currently I am using the following piece of code in my Webapplication. This starts a new command window and executes the WebRunnerTestCase.

String cmdLine = "cmd /c start testrunner.bat -r -c WebRunnerTestCase D:/soapUIprojects/DBDrivenTest-soapui-project.xml";
       Process proc = Runtime.getRuntime().exec(commandLine.toString(), null, soapUIBinDir);

The problem with this solution is that if the server is running on some remote system this will not work. Is there any way i can trigger the execution of com.eviware.soapui.SoapUIProTestCaseRunner from a Web Application?

Would appreciate any suggestion.
Regards
T
5  soapUI / soapUI / Re: Setting the query of a JDBC datasource dynamically in TestCase setupScript on: February 01, 2008, 05:30:06 pm
Thanks Ole. You suggestions as always was spot on.
6  soapUI / soapUI / Setting the query of a JDBC datasource dynamically in TestCase setupScript on: January 31, 2008, 08:48:39 pm
Hi,
Is it possible to set the query for a JDBC DataSource dynamically through the SetUp script of a TestCase?

I have to fetch the query from a DB in the SetUp script and set it in the dataSource which has already been created

def dataSource    = testRunner.getTestCase().getTestStepByName("DataSource")
7  soapUI / soapUI / Re: Adding assertions to TestRequest dynamically using Groovy on: January 24, 2008, 08:51:27 pm
Thanks a lot for the code snippet that was what i was looking for. Using the following script I was able to achieve what i was trying to do.

def assertionsList = testRunner.getTestCase().getTestStepByName("Test Request").getAssertionList()
for( e in assertionsList){
   testRunner.getTestCase().getTestStepByName("Test Request").removeAssertion(e)
}

def testCaseName = testRunner.getTestCase().getTestStepByName("DataSource").getPropertyValue("test_case_name")
def assertText = testRunner.getTestCase().getTestStepByName("DataSource").getPropertyValue("assert_text")
def assertion = testRunner.getTestCase().getTestStepByName("Test Request").addAssertion("XPath Match")

println " \n\n ########## Start TestCase Name " + testCaseName
assertion.name = testCaseName
assertion.path = assertText
assertion.expectedContent = true

Thanks once again
8  soapUI / soapUI / Re: Adding assertions to TestRequest dynamically using Groovy on: January 22, 2008, 10:33:49 pm
Hi Ole,
I am trying to add XPath Match assertion. The api for addAssertion does not take any assertionType parameter, all it takes is a String which I am assuming is the XPath eg:
declare namespace ns1='http://nextel.com/ovm';
//ns1:ovm/ns1:ovm-response/ns1:plans-response/ns1:price-plan/ns1:plan-id = 'FF1001H'


Regards
9  soapUI / soapUI / Adding assertions to TestRequest dynamically using Groovy on: January 22, 2008, 10:08:45 pm
Hi,
I have an urgent requirement in my project which needs to be implemented.
The requirement is that all the Input XML and the XPath assertions will be moved to the database.
The project file will not have the input XML or assertions in the Test Request.
To execute this we have created the following steps.
1. Datasource step to read the request_xml and assertion_text from DB
select request_xml, test_case_name, request_id, assert_text
  from TEST_REQUEST_DATA A, ASSERTIONS_DATA B
  where A.REQUEST_ID = B.ASSERT_REQUEST_ID
 
2. Property Transfer step to feed the request_xml property from the DataSource to the TestRequest Step.

3. Groovy Script to add assertions to the Test Request by getting the assertion_text from the DataSource

def assertText = testRunner.getTestCase().getTestStepByName("DataSource").getPropertyValue("assert_text")
testRunner.getTestCase().getTestStepByName("Test Request").addAssertion(assertText)

Step 3 fails giving the following exception
2008-01-22 14:53:29,125 ERROR [errorlog] java.lang.NullPointerException
java.lang.NullPointerException
   at com.eviware.soapui.impl.wsdl.panels.teststeps.AssertionsPanel$AssertionListModel.addAssertion(AssertionsPanel.java:358)
   at com.eviware.soapui.impl.wsdl.panels.teststeps.AssertionsPanel$AssertionListModel.assertionAdded(AssertionsPanel.java:350)
   at com.eviware.soapui.impl.wsdl.support.assertions.AssertionsSupport.fireAssertionAdded(AssertionsSupport.java:135)
   at com.eviware.soapui.impl.wsdl.teststeps.WsdlTestRequest.addAssertion(WsdlTestRequest.java:187)
   at com.eviware.soapui.impl.wsdl.teststeps.WsdlTestRequestStep.addAssertion(WsdlTestRequestStep.java:539)
   at gjdk.com.eviware.soapui.impl.wsdl.teststeps.WsdlTestRequestStep_GroovyReflector.invoke(Unknown Source)
   at groovy.lang.MetaMethod.invoke(MetaMethod.java:115)
   at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:713)
   at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:560)
   at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:450)
   at org.codehaus.groovy.runtime.Invoker.invokeMethod(Invoker.java:119)
   at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:111)
   at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:187)
   at Script1.run(Script1.groovy:14)
   at com.eviware.soapui.support.scripting.groovy.SoapUIGroovyScriptEngine.run(SoapUIGroovyScriptEngine.java:59)
   at com.eviware.soapui.support.scripting.groovy.SoapUIProGroovyScriptEngineFactory$SoapUIProGroovyScriptEngine.run(SourceFile:51)
   at com.eviware.soapui.impl.wsdl.teststeps.WsdlGroovyScriptTestStep.run(WsdlGroovyScriptTestStep.java:140)
   at com.eviware.soapui.impl.wsdl.panels.teststeps.GroovyScriptStepDesktopPanel$RunAction.actionPerformed(GroovyScriptStepDesktopPanel
   
   
My question is:
Is it possible to dynamically add assertions to a TestRequest?
And if it is could you please point out where I am going wrong.
Would appreacite any help with this problem.
Best Regards
tareque
10  soapUI / soapUI / Data Driven Test Failing on: January 03, 2008, 09:40:41 pm
Hi,
I have created a data driven test in soapUI Pro. This test reads XML input from a spreadsheet and submits the request, the response is then validated using XPath assertions. This TestCase is working in soapUI Pro1.7.6 but not in soapUI Pro 2.0. After inspecting the input I noticed that in soapUI Pro 2.0 a header is being inserted in the input XML
   <Header>
      <wsse:Security null:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">
         <wsu:Timestamp wsu:Id="Timestamp-1514139" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
            <wsu:Created>2008-01-03T20:35:02.203Z</wsu:Created>
            <wsu:Expires>2008-01-05T00:21:42.203Z</wsu:Expires>
         </wsu:Timestamp>
      </wsse:Security>
   </Header>

Can you advise how we can remove this header so that I do not get the XML validation error that I am getting now because of this header.
Regards
11  soapUI / soapUI / Request timing out on: November 26, 2007, 06:55:01 pm
Hi,
I have create a new Test Request which is timing out when the Database is slow or when i try to debug the application. The exception is
Mon Nov 26 12:51:47 EST 2007:ERROR:Exception in request: java.net.SocketTimeoutException: Read timed out
Mon Nov 26 12:51:47 EST 2007:ERROR:An error occured [Read timed out], see error log for details
Mon Nov 26 12:51:47 EST 2007:INFO:Error getting response for [WSDLGatewaySoapBinding.processRequest:Test Request]; java.net.SocketTimeoutException: Read timed out

Is there any way I can increase the timeout for this request?
Regards
12  soapUI / soapUI / Re: Assert using XPath in XML contained in CDATA on: November 19, 2007, 10:00:49 pm
Hi,
I was able to make the groovy script simpler by introducing a PropertyTransfer and a Properties object. The groovy script now is as follows

def utils = new com.eviware.soapui.support.GroovyUtils(context)
def value = testRunner.testCase.getTestStepByName("Properties").getPropertyValue("XML")
def holder = utils.getXmlHolder(value)
assert holder.getNodeValue("//ns1:ovm-error-info/ns1:error-code") == '254'


Is this a good approach or is there a better way to do this.
Regards
13  soapUI / soapUI / Assert using XPath in XML contained in CDATA on: November 16, 2007, 05:06:18 pm
Hi Ole,
I am trying to add XPath assertions to validate the data that I am getting in a request that has an XML as one of the tag values enclosed in CDATA section. I am able to do it using this Groovy script,
def request = testRunner.testCase.getTestStepByName("AsyncMockResponse").getProperty("request");
println "\n Async Request "
def node = new groovy.util.XmlParser(false,false).parseText(request.value);
def input = node["soapenv:Body"]["ns1:processRequest"]["incomingXml"]
def requestXml = new groovy.util.XmlParser(false,false).parseText(input.value);
def tagValue = requestXml.children()["error-code"]
println tagValue.value.toString()
if(tagValue.value.toString() == '[144]'){
   println "You passed"
}else{
   println "You failed"
   throw new Exception("You failed")
}

Is there a better way to do it using just XPATH.
Regards


PS. I am also attaching a snippet of the XML that I am trying to validate.
<ns1:processRequest soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="urn:WSDLGateway" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <incomingXml xsi:type="soapenc:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"><![CDATA[<ovm xmlns="http://next.com/ovm" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://next.com/ovm http://localhost:8000/ovm/xsd/ovm-response.xsd">
    <ovm-error-info>
        <error-type>2</error-type>
        <error-code>144</error-code>
        <error-details>This is a corporate/government order, but no corporate/government identifier was sent.</error-details>
    </ovm-error-info>
</ovm>]]></incomingXml>
  <dealer xsi:type="soapenc:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"/>
  <msgType xsi:type="soapenc:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"/>
  <systemIndicator xsi:type="soapenc:string" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"/>
</ns1:processRequest>
14  soapUI / soapUI / Re: Asynchronous Testing using soapUI pro on: November 16, 2007, 04:14:50 pm
Hi Ole,
We were able to resolve the issue. The problem was with our WSDL and not anything to do with soapUI.
Regards
15  soapUI / soapUI / Re: Asynchronous Testing using soapUI pro on: November 12, 2007, 11:37:33 pm
Hi Ole,
Mock response works for requests that are generated from soapUI but when an asynchronous client creates a request and invokes the MockResponse service it gives an exception

Mon Nov 12 17:08:41 EST 2007:WARN:EXCEPTION
   javax.servlet.ServletException: com.eviware.soapui.impl.wsdl.mock.DispatchException: Missing operation for soapAction [""] and body element [{http://localhost:8000/ovm/WSDLGateway}processRequest] with SOAP Version [SOAP 1.1]
      at com.eviware.soapui.monitor.MockEngine$ServerHandler.handle(MockEngine.java:246)
      at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
      at org.mortbay.jetty.Server.handle(Server.java:313)
      at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:506)
      at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:844)
      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644)
      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
      at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:396)
      at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)
   Caused by: com.eviware.soapui.impl.wsdl.mock.DispatchException: Missing operation for soapAction [""] and body element [{http://localhost:8000/ovm/WSDLGateway}processRequest] with SOAP Version [SOAP 1.1]
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:50)
      at com.eviware.soapui.monitor.MockEngine$ServerHandler.handle(MockEngine.java:236)
      ... 9 more
Mon Nov 12 17:08:41 EST 2007:WARN:Nested in javax.servlet.ServletException: com.eviware.soapui.impl.wsdl.mock.DispatchException: Missing operation for soapAction [""] and body element [{http://localhost:8000/ovm/WSDLGateway}processRequest] with SOAP Version [SOAP 1.1]:
   com.eviware.soapui.impl.wsdl.mock.DispatchException: Missing operation for soapAction [""] and body element [{http://localhost:8000/ovm/WSDLGateway}processRequest] with SOAP Version [SOAP 1.1]
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:259)
      at com.eviware.soapui.impl.wsdl.mock.WsdlMockRunner.dispatchRequest(WsdlMockRunner.java:50)
      at com.eviware.soapui.monitor.MockEngine$ServerHandler.handle(MockEngine.java:236)
      at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
      at org.mortbay.jetty.Server.handle(Server.java:313)
      at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:506)
      at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:844)
      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644)
      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
      at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:396)
      at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)


Pages: [1] 2


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
header header
header
header