Hi,
I have the same issue, "The scenario completes, but the analysis fails", and I've tried all the solutions mentioned in the above threads:
Windows 7 Enterprise,
Jenkins version 2.7.1,
LoadRunner 12.53 No patches,
Post Build Actions: Do not archive HP test reports,
The .lrs scenario and all components of Loadrunner are installed on the Jenkins server,
Not using the Jenkins Local System Account User Type,
No boxes are checked under Set Results Directory dialog,
The tools->Templates and Reports->Report Templates are set to factory default just like in the pictures Ethan provided,
Running the scenario outside of Jenkins then viewing the results in Analysis works fine
The Analyzing results... section of the Console Output states that:
The Analysis launcher gets passed the arguments: "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRR\LRR.lrr" "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRA\LRA.lra" "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\HTML\HTML.html"
However the Directory HTML and all of its contents under 4ecd5c is missing on my machine. How/when does the path and the HTML.HTML file get created and what could prevent it's creation? Subsequently, the Analyzing results... sections states:
Loader Manager initialization failed.
at Analysis.ApiSL.ApiSlRuntimeErrors.Throw(Int32 aErrorCode, ApiException aException)
at Analysis.ApiSL.ApiSlRuntimeErrors.UnsafeCode(UnsafeCodeHandlerBool aHandler, Int32 aLraErrorCode)
at Analysis.Api.Session.CreateWithTemplateFile(String aSessionName, String aResultFileName, String aTemplateFileName)
at LRAnalysisLauncher.Program.Main(String[] args)
and reports that an error occurred during the Analysis run.
Jenknis Console Output:
log
props23022017071217048.txt
build.xml
config.xml
junitResult.xml
changelog.xml
Started by user EB <http://ComputerName:8080/user/EB>
Building in workspace C:\Jenkins\workspace\EclipseLR_Scenario
[EclipseLR_Scenario] $ C:\Jenkins\workspace\EclipseLR_Scenario\HpToolsLauncher.exe -paramfile props23022017071217048.txt
"Started..."
Launcher timeout is 00::00:10:00
reading PerScenarioTimeout: 600
PerScenarioTimeout: 10:00:00 minutes
PerScenarioTimeout: 00::10:00:00 minutes FileSystemTestRunner timeout is 00:10:00 Mc connection info is - Mc HostAddress: , McPort: 8080, Username: , UseSSL: 0, UseProxy: 0, ProxyType: 0, ProxyAddress: , ProxyPort: 0, ProxyAuth: 0, ProxyUser:
1 tests found:
C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs
============================================================================
23/02/2017 07:12:17 Running: C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs
Cleaning up the environment...
wlrun killed
Preparing scenario C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs for execution.
Load Generator localhost connected
setting scenario result folder to C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRR
scenario result folder: C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRR
Starting scenario...
Scenario C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs ended after 0:0:30.
============================================================================
Analyzing results...
closing Controller
Controller closed
calling analysis report generator
executing Analysis launcher with arguments : "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRR\LRR.lrr" "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\LRA\LRA.lra" "C:\Jenkins\workspace\EclipseLR_Scenario\4ecd5c\HTML\HTML.html"
time for analysis: 00::10:00:00
starting analysis launcher
creating analysis COM object
creating analysis session
Loader Manager initialization failed.
at Analysis.ApiSL.ApiSlRuntimeErrors.Throw(Int32 aErrorCode, ApiException aException)
at Analysis.ApiSL.ApiSlRuntimeErrors.UnsafeCode(UnsafeCodeHandlerBool aHandler, Int32 aLraErrorCode)
at Analysis.Api.Session.CreateWithTemplateFile(String aSessionName, String aResultFileName, String aTemplateFileName)
at LRAnalysisLauncher.Program.Main(String[] args) time passed: 00::00:00:03
Error: Error during Analysis run. See output console for details analysis report generator finished
Error(s) summary:
0 ignored , 0 errors
Test PASSED
Test result: Error
23/02/2017 07:13:42 Test complete: C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs
-------------------------------------------------------------------------------------------------------
Cleaning up the environment...
================================================
Run status: Job failed, total tests: 1, succeeded: 0, failures: 0, errors: 1 Error : C:\2-16-17\LR_Selenium_N__Net_Scenario_2-16-17.lrs
================================================
Build step 'Execute HP tests from file system' changed build result to FAILURE
Finished: FAILURE
It's not necessary when running using Jenkins - since the plugin tries to create new directory regardless of this option.
I will try to reproduce it on the same LR version you have ( the plugin is constantly tested on the latest versions of LR) to see if it's LR 12.02 specific issue or a plugin issue.