Forum Discussion

Joe_DuBois's avatar
Joe_DuBois
Occasional Contributor
17 years ago

Unknown Protocol: C (testrunner.bat)

Trying to run my Project/tests from the command line (to make sure it runs before I integrate it with Maven).

I am using the following command:
testrunner.bat -hlocalhost:8080 -a -fresults C:\workplace\work\Testing\soapUI\OraderWS-soapui-project.xml

The test runs perfect fine from the IDE/GUI. I have re-saved the project, just to make sure it was the latest project file.

Output from running command:
C:\Utils\soapui\bin>testrunner.bat -hlocalhost:8080 -a -fresults C:\workplace\work\Testing\soapUI\OraderWS-soapui-projec
t.xml
soapUI 2.5 TestCase Runner
Configuring log4j from [C:\Utils\soapui\bin\soapui-log4j.xml]
12:58:49,759 INFO  [SoapUI] Added [file:/C:/Utils/soapui/bin/ext/ojdbc14.jar] to classpath
12:58:50,400 INFO  [DefaultSoapUICore] initialized soapui-settings from [C:\Utils\soapui\bin\soapui-settings.xml]
12:58:52,431 ERROR [SoapUI] An error occured [unknown protocol: c], see error log for details
java.net.MalformedURLException: unknown protocol: c
        at java.net.URL.(URL.java:574)
        at java.net.URL.(URL.java:464)
        at java.net.URL.(URL.java:413)
        at com.eviware.soapui.impl.wsdl.WsdlProject.(WsdlProject.java:181)
        at com.eviware.soapui.impl.wsdl.WsdlProjectFactory.createNew(WsdlProjectFactory.java:29)
        at com.eviware.soapui.impl.wsdl.WsdlProjectFactory.createNew(WsdlProjectFactory.java:12)
        at com.eviware.soapui.tools.SoapUITestCaseRunner.runRunner(SoapUITestCaseRunner.java:241)
        at com.eviware.soapui.tools.AbstractSoapUIRunner.run(AbstractSoapUIRunner.java:118)
        at com.eviware.soapui.tools.AbstractSoapUIRunner.runFromCommandLine(AbstractSoapUIRunner.java:70)
        at com.eviware.soapui.tools.SoapUITestCaseRunner.main(SoapUITestCaseRunner.java:92)
12:58:52,634 ERROR [SoapUITestCaseRunner] java.lang.Exception: Failed to load soapUI project file [C:\workplace\work\Tes
ting\soapUI\OraderWS-soapui-project.xml]
12:58:52,634 ERROR [SoapUI] An error occured [Failed to load soapUI project file [C:\workplace\work\Testing\soapUI\Orade
rWS-soapui-project.xml]], see error log for details
java.lang.Exception: Failed to load soapUI project file [C:\workplace\work\Testing\soapUI\OraderWS-soapui-project.xml]
        at com.eviware.soapui.tools.SoapUITestCaseRunner.runRunner(SoapUITestCaseRunner.java:244)
        at com.eviware.soapui.tools.AbstractSoapUIRunner.run(AbstractSoapUIRunner.java:118)
        at com.eviware.soapui.tools.AbstractSoapUIRunner.runFromCommandLine(AbstractSoapUIRunner.java:70)
        at com.eviware.soapui.tools.SoapUITestCaseRunner.main(SoapUITestCaseRunner.java:92)
  • Joe_DuBois's avatar
    Joe_DuBois
    Occasional Contributor
    Ok, tried running the test from Maven (which is the final goal) and this is part of the log that I got. It is failing the tests. Again the tests run fine from  the IDE/GUI but are failing from the Commandline or Maven.

    This error seems to be Unsupported Media type, so not sure if that is the same as Unknown Protocol: C.


    [INFO] [soapui:test]
    [DEBUG] Setting context classloader for plugin to: /plugins/eviware:maven-soapui-plugin:1.7.6@48/thread:main (instance is: ClassRealm[/plugins/eviware:maven-soapui-plugin:1.7.6@48/thread:main, parent: ClassRealm[plexus.core, parent: null]])
    soapUI 1.7.6 Maven2 TestCase Runner
    Configuring log4j from [jar:file:/C:/Documents%20and%20Settings/dubois_j/.m2/repository/eviware/soapui/1.7.6/soapui-1.7.6.jar!/soapui-log4j.xml]
    10:23:07,306 INFO  [SoapUI] Added [file:/C:/workspace/Order-Service/ext/ojdbc14.jar] to classpath
    10:23:07,322 INFO  [DefaultSoapUICore] Creating new settings at [C:\workspace\Order-Service\soapui-settings.xml]
    10:23:07,853 INFO  [WsdlProject] Loaded project from [file:/C:/workspace/Order-Service/test/resources/OrderWS-soapui-project.xml]
    10:23:07,947 INFO  [SoapUITestCaseRunner] Running soapUI tests in project [OrderWS]
    10:23:07,947 INFO  [SoapUITestCaseRunner] Running soapUI suite [TestMedicationOrder], runType = SEQUENTIAL
    10:23:07,947 INFO  [SoapUITestCaseRunner] Running soapUI testcase [TestCase 1]
    10:23:07,947 INFO  [SoapUITestCaseRunner] running step [getMedicationOrder - Request 1]
    10:23:08,306 INFO  [HttpClientSupport$Helper] Initializing SSL
    10:23:08,462 INFO  [SoapUITestCaseRunner] Assertion [SOAP Response] has status FAILED
    10:23:08,462 ERROR [SoapUITestCaseRunner] ASSERTION FAILED -> null/empty response
    10:23:08,462 INFO  [SoapUITestCaseRunner] Assertion [Schema Compliance] has status FAILED
    10:23:08,462 ERROR [SoapUITestCaseRunner] ASSERTION FAILED -> null/empty response
    10:23:08,462 INFO  [SoapUITestCaseRunner] Assertion [Contains] has status FAILED
    10:23:08,462 ERROR [SoapUITestCaseRunner] ASSERTION FAILED -> null/empty response
    10:23:08,462 ERROR [SoapUITestCaseRunner] getMedicationOrder - Request 1 failed, exporting to [TestMedicationOrder-TestCase 1-getMedicationOrder - Request 1-0-FAILED.txt]
    10:23:08,462 INFO  [SoapUITestCaseRunner] Finished running soapUI testcase [TestCase 1], time taken: 109ms, status: FAILED
    10:23:08,462 INFO  [SoapUITestCaseRunner] soapUI suite [TestMedicationOrder] finished in 515ms
    [ERROR] java.lang.Exception: SOAP Response in [getMedicationOrder - Request 1] failed;
    [null/empty response]
    Status: FAILED
    Time Taken: 109
    Size: 0
    Timestamp: Tue Dec 09 10:23:07 EST 2008
    TestStep: getMedicationOrder - Request 1
    null/empty response
    null/empty response
    null/empty response
    ----------------------------------------------------
    Encoding: UTF-8
    Endpoint: http://127.0.0.1:9990/OrderWS/OrderWS
    Username: null
    Password: null
    Domain: null
    ---------------- Request ---------------------------

     

     
         
            788652
         

     

    Request Headers: {Content-Length=322, Host=127.0.0.1:9990, User-Agent=Jakarta Commons-HttpClient/3.0.1, Content-Type=application/soap+xml;charset=UTF-8;action=http://business.medication.order.ws.chboston.org//getMedicationOrder}
    ---------------- Response --------------------------
    Response Headers: {Connection=Keep-Alive, #status#=HTTP/1.1 415 Unsupported Media Type, Keep-Alive=timeout=15, max=100, Date=Tue, 09 Dec 2008 15:23:07 GMT, Content-Type=application/soap+xml, Server=Oracle Containers for J2EE, Transfer-Encoding=chunked}
  • Robert_Nemet's avatar
    Robert_Nemet
    Occasional Contributor
    Hello,

    I can not reproduce it. I wonder what version you are using? I noticed that maven plugin is 1.7.6.
    Can you send me project file so I can try, please?

    Robert
    email:robert@eviware.com
  • Joe_DuBois's avatar
    Joe_DuBois
    Occasional Contributor
    Attached is the project file, though not sure if you can truly test it as the Service is behind our Firewall, which I will not be able to open up because of security.


    Also included here are the pom.xml file tags/code that we are trying to use for the Maven plugin.

    We have a Target of clean and test

    Under

             
                  eviware
                  maven-soapui-plugin
                  1.7.6
                 
                      ${basedir}/test/resources/OrderWS-soapui-project.xml
                     

                      127.0.0.1:9990
                 

                 
                     
                          test
                         
                              test
                         

                     

                 

             


    Then we have:

         
        eviwarePluginRepository
        http://www.eviware.com/repository/maven2/