Forum Discussion

pkinoc's avatar
pkinoc
Occasional Contributor
12 years ago

Problems generating report from command line

If I run the following script then the last line will show that the pdf report is generated and the file is actually there but if I change the name of the report slightly it doesn't work. The name I am using was taken from an example on the soapui website.

c:\windows\system32\cmd.exe /C testrunner.bat -FPDF -R"Project Report" "C:\Users\Test Automation scripts\WESB-ImpactHappyPath-1148-soapui-project.xml"


C:\Users\pekelly>"C:\Users\Test Automation scripts\Automation2_PDF.bat"
soapUI Pro 4.5.0 TestCase Runner
08:27:21,380 INFO [SoapUI] Adding [C:\Program Files (x86)\SmartBear\soapUI-Pro-4.5.0\bin\ext\classes12.jar] to extensions classpath
08:27:21,797 INFO [DefaultSoapUICore] initialized soapui-settings from [C:\Users\pekelly\soapui-settings.xml]
08:27:22,074 WARN [SoapUIProGroovyScriptEngineFactory] Missing scripts folder [C:\PROGRA~2\SMARTB~1\SOAPUI~1.1\bin\scripts]
08:27:22,076 INFO [DefaultSoapUICore] Adding listeners from [C:\Program Files (x86)\SmartBear\soapUI-Pro-4.5.0\bin\listeners\demo-listeners.xml]
08:27:23,118 INFO [WsdlProject] Loaded project from [file:/C:/Users/Test%20Automation%20scripts/WESB-ImpactHappyPath-1148-soapui-project.xml]
08:27:23,351 WARN [SoapUIProGroovyScriptEngineFactory] Missing scripts folder [C:\PROGRA~2\SMARTB~1\SOAPUI~1.1\bin\scripts]
08:27:23,957 INFO [SoapUIProTestCaseRunner] Running soapUI tests in project [WESB_ImpactHappyPath-1148]
08:27:24,022 INFO [SoapUIProTestCaseRunner] Running Project [WESB_ImpactHappyPath-1148], runType = SEQUENTIAL
08:27:24,096 INFO [SoapUIProTestCaseRunner] Running soapUI testcase [TestCase 1 - Open Title Order in SVO]
08:27:24,968 INFO [SoapUIProTestCaseRunner] running step [Groovy Script - TIMESTAMP clause]
08:27:25,529 INFO [log] Current Little Rock timestamp= 2012-06-20 10:27:25
08:27:25,532 INFO [SoapUIProTestCaseRunner] running step [Delay in case client/server times not in sync]
08:27:27,533 INFO [SoapUIProTestCaseRunner] running step [DataSource - OrderNumber]
08:27:27,535 INFO [SoapUIProTestCaseRunner] running step [Groovy Script - Get Next Order Number]
08:27:27,578 INFO [log] Last OrderID= OrderID=81080241
08:27:27,582 INFO [log] OrderID= 81080241
08:27:27,588 INFO [log] New OrderID= 81080242
08:27:27,596 INFO [SoapUIProTestCaseRunner] running step [Request 1 - T of TE]
08:27:27,857 DEBUG [HttpClientSupport$SoapUIHttpClient] Attempt 1 to execute request
08:27:27,857 DEBUG [SoapUIMultiThreadedHttpConnectionManager$SoapUIDefaultClientConnection] Sending request: POST /ImpactESBOrderGatewayWeb/ImpactESBOrderPost HTTP/1.1
.
.
.
08:17:45,092 INFO [SoapUIProTestCaseRunner] Finished running soapUI testcase [TestCase 3 - Open Title Order in NextAce], time taken: 6294ms, status: FINISHED
08:17:45,094 INFO [SoapUIProTestCaseRunner] Project [WESB_ImpactHappyPath-1148] finished with status [FINISHED] in 24328ms
08:17:50,014 INFO [SoapUIProTestCaseRunner] Created report [Project Report] to path [C:\Users\pekelly\Project Report.pdf]


but if I add an s to the report name nothing is generated:

C:\Users\pekelly>c:\windows\system32\cmd.exe /C testrunner.bat -FPDF -R"Project Reports" "C:\Users\Test Automation scripts\WESB-ImpactHappyPath-1148-soapui-project.xml"
soapUI Pro 4.5.0 TestCase Runner
08:29:31,944 INFO [SoapUI] Adding [C:\Program Files (x86)\SmartBear\soapUI-Pro-4.5.0\bin\ext\classes12.jar] to extensions classpath
08:29:32,358 INFO [DefaultSoapUICore] initialized soapui-settings from [C:\Users\pekelly\soapui-settings.xml]
08:29:32,634 WARN [SoapUIProGroovyScriptEngineFactory] Missing scripts folder [C:\PROGRA~2\SMARTB~1\SOAPUI~1.1\bin\scripts]
08:29:32,636 INFO [DefaultSoapUICore] Adding listeners from [C:\Program Files (x86)\SmartBear\soapUI-Pro-4.5.0\bin\listeners\demo-listeners.xml]
08:29:33,684 INFO [WsdlProject] Loaded project from [file:/C:/Users/Test%20Automation%20scripts/WESB-ImpactHappyPath-1148-soapui-project.xml]
08:29:33,923 WARN [SoapUIProGroovyScriptEngineFactory] Missing scripts folder [C:\PROGRA~2\SMARTB~1\SOAPUI~1.1\bin\scripts]
08:29:34,523 INFO [SoapUIProTestCaseRunner] Running soapUI tests in project [WESB_ImpactHappyPath-1148]
08:29:34,587 INFO [SoapUIProTestCaseRunner] Running Project [WESB_ImpactHappyPath-1148], runType = SEQUENTIAL
08:29:34,662 INFO [SoapUIProTestCaseRunner] Running soapUI testcase [TestCase 1 - Open Title Order in SVO]
08:29:35,518 INFO [SoapUIProTestCaseRunner] running step [Groovy Script - TIMESTAMP clause]
08:29:36,095 INFO [log] Current Little Rock timestamp= 2012-06-20 10:29:35
08:29:36,099 INFO [SoapUIProTestCaseRunner] running step [Delay in case client/server times not in sync]
08:29:38,099 INFO [SoapUIProTestCaseRunner] running step [DataSource - OrderNumber]
08:29:38,101 INFO [SoapUIProTestCaseRunner] running step [Groovy Script - Get Next Order Number]
08:29:38,144 INFO [log] Last OrderID= OrderID=81080242
08:29:38,147 INFO [log] OrderID= 81080242
08:29:38,151 INFO [log] New OrderID= 81080243
08:29:38,158 INFO [SoapUIProTestCaseRunner] running step [Request 1 - T of TE]
08:29:38,434 DEBUG [HttpClientSupport$SoapUIHttpClient] Attempt 1 to execute request
08:29:38,434 DEBUG [SoapUIMultiThreadedHttpConnectionManager$SoapUIDefaultClientConnection] Sending request: POST /ImpactESBOrderGatewayWeb/ImpactESBOrderPost HTTP/1.1
08:29:40,291 DEBUG [SoapUIMultiThreadedHttpConnectionManager$SoapUIDefaultClientConnection] Receiving response: HTTP/1.1 200 OK
08:29:40,297 DEBUG [HttpClientSupport$SoapUIHttpClient] Connection can be kept alive indefinitely
.
.
.
08:30:49,665 INFO [SoapUIProTestCaseRunner] Finished running soapUI testcase [TestCase 3 - Open Title Order in NextAce], time taken: 7691ms, status: FINISHED
08:30:49,668 INFO [SoapUIProTestCaseRunner] Project [WESB_ImpactHappyPath-1148] finished with status [FINISHED] in 28172ms

C:\Users\pekelly>


what am I doing wrong?

3 Replies

  • SmartBear_Suppo's avatar
    SmartBear_Suppo
    SmartBear Alumni (Retired)
    Hi,

    the name you specify with the -R argument is the name of the report template to use for generating the report, and since the project level report template is named "Project Report" that is the only name that works at this level.

    regards!

    /Ole
    SmartBear Software
  • pkinoc's avatar
    pkinoc
    Occasional Contributor
    Not obvious at all from the documentation!

    R : Selects which report to generate for the test objects executed, for example if running the entire project, this could specify the name of a test-suite-level report that would be generated for each TestSuite. The report is saved as specified with the -F option to the folder specified with the -f option. (soapUI Pro only)
  • SmartBear_Suppo's avatar
    SmartBear_Suppo
    SmartBear Alumni (Retired)
    Hi,

    I agree - this is badly formulated - thanks for pointing it out, and sorry for the confusion!

    regards,

    /Ole
    SmartBear Software