TOSCA Continues Integration with Team City
After installing TOSCA 9.3, TOSCA CI related program should be under C:\Program Files (x86)\TRICENTIS\Tosca Testsuite\ToscaCommander\ToscaCI.
Preparation in TOSCA work space
- Create a execution list folder and set attribute ContinuousIntegrationBuildRootFolder to True
- Create execution list with attribute ContinuousIntegration=True and a desired value for Executiontype Add test cases which you plan to execute to this execution list.
TOSCA CI Client
TOSCA CI professional license is required for using CI configuration file.
Since we will trigger the execution from TeamCity, the TOSCA CI client could be triggered under system account, under that the UI automation will be blocked. So the TOSCA CI Remote Execution Service will be used to execute the test cases.
In this case, we will only need to configure the remote execution service endpoint. It could be on local or remote machine, but it should be started under normal admin account.
TOSCA CI Remote Execution Service
Attributes below in ToscaCIRemoteExecutionService.exe.config should be configured based on your configuration.
- WorkspacePath
- LoginName
- LoginPassword
Unattended Execution
- The screen saver should be disabled
- The system should not be locked at any time, a action RDP session should be kept
- Or Auto logon is enabled, and use VNC or teamviewer to remote connect to the system
- the system is logged in with the same user which starts the ToscaCIRemoteExecutionService
Team City Integration
Build Steps
Generate TOSCA CI configuration file
- Runner Type: Powershell
- Script: Source
- Script source:
Tests Execution
- Runner Type: Command Line
- Run: Executable with parameters
- Command executable: C:\Program Files (x86)\TRICENTIS\Tosca Testsuite\ToscaCommander\ToscaCI\Client\ToscaCIClient.exe
- Command parameters:-m distributed -c “c:\Temp\CIExeConfig.xml” -t junit -r “c:\temp\result.xml” -x True
Display test result in Team City
In Build features, add a new build feature with following details:
- Report Type: Ant JUnit
- Monitoring rules: c:\temp\result.xml