...
Click OK togo to the Configuration page.
To configure enter the Job Description under General settings.
Now set up the build steps, go to the Build Steps tab
Click Add a build step.
If you are using a Windows machine, select Execute Windows batch command.
In the Command text box, enter the command to execute qualitia-offline.xxxx.jar.
For example: If your offline package is stored in the D > OfflinePackage, enter the command to navigate to the D drive and then command to execute the offline package.First command hits Qualitia Bot API endpoints to generate a executionAgent.jar. This jar is bridge between CI tool (in this case Jenkins) and Qualitia Server for provided server URL.
In second command, utilize this bridge and provide arguments to access required artifacts.
The required parameters are:
ServerUrl: The server URL where your server is hosted.
ProjectName: The name of the project for which you want to execute testcases and suites.
SuiteName: The name of the suite which you want to execute using Jenkins integration.
Executiontrigger: The mode of execution that you want to trigger from Jenkins.
You can provide any arguments using this command like browser, driver path, polling interval etc.
During the execution, Qualitia engine creates a property file qer.properties which will help you to read report in CI/CD.
Make sure to install Inject environment variables plugin to read this file. Once you install this plugin, select Inject environment variables option in Build Steps.
Provide a complete path of qer.properties.
Next step is to set up Post-build Actions to get an execution report.
Go to Post-build Actions and click Add post-build action.
To publish execution report, install Publish HTML Reports plugin.
Select Publish HTML Reports option.
Add values we read from qer.properties in previous step.
To publish the report.
HTML directory to archive: Enter the HTML directory path where report exists. Provide variable present in qer.properties for HTML directory where report exists.
Index page[s]: Enter variable reportfilename in qer.properties. This is the page users want to publish.
Report title: Provide any name of your choice for the file.
Click Apply and then save the data by clicking Save.
Once the setup is done. Click Build Now.
If the job is successfully executed, it will publish a report in Jobs.
Download the Zip file and take a glance at it. It downloads all the supported files for reports as well.
You can also view the complete build history in the left pane under Build History.
...
🔧 Got a problem? Let’s fix!
Unable to view Qualitia Suite Execution Summary Report in Jenkins
Problem: After an offline suite is executed using a Jenkins Job, the associated suite execution report is not displayed in Jenkins Reports.
Description: When you open the published suite execution report in Jenkins, you see any of the following behavior:
A blank page opens
The following message is displayed:
“You need to enable JavaScript to view this”
Solution:
You need to set up the content policy in Jenkins.
Perform the following steps:
Open the Jenkins Server.
Click Manage Jenkins >Manage Nodes.
Click the Settings icon for the node that you are using (Master node by default).
In the node page, select the Script Console option in the side menu.
In the script console, enter the following command line: System.setProperty("hudson.model.DirectoryBrowserSupport.CSP", "default-src 'self' 'unsafe-inline';")
Click the Run button below to this console, and you should see the Result: with the above values printed.
Note: If you don’t see it in the first attempt, then retry this step.
You can now see the suite execution summary reports.
📞📚 Here to Help: Support and Resources
Need a helping hand? Don't hesitate to reach out to your Qualitia Relationship Manager. For more resources, our official Qualitia documentation and community website are just a click away!
Add label