I am using HTML publisher plugin to report a html file from Surefire reports generated in /target/** folder, but when I click on HTML report on the project page it redirects me to only previous build and not the ones built before that.
My use case is that there are 3 stages in my test suite and I want to publish a report for each stage separately or provide a link to it. If not HTML publisher, which other plugin would you suggest for my use case?
Related
I am using cucumber.js and producing a .json report after an execution. I am executing my tests from a Jenkins which is not connected to any internet.
I am using cucumber-html-reporter to generate the html report. The html report is created but the report on the Jenkins is not displayed correctly. Styles and css are broken as it is not able to download it.
Any way by which i can display the html report correctly without breaking images and styles on the Jenkins without having any access to internet. Or any other reporter which I can use to display the report correctly.
I am assuming that you have added the dependency in your maven project to generate the reports. I believe you must check this plugin.
https://plugins.jenkins.io/cucumber-reports/
You can install the aforementioned plugin in your jenkins instance and then you can publish the json report with the help of this plugin. Otherwise you can create your custom html report by reading the required data from cucumber json report and once it is done, you can publish that html report in the jenkins.
It is even worthy to check the below jar file that I have created for the cucumber reporting.
https://github.com/frostyaxe/CucuReporter
I'm developing a Jenkins plugin for displaying reports of my own tool. I got difficulties because Jenkins lacks documentation for developing plugins. Currently, my plugin can only display report on a build page
Screenshoot (surroneded by red border):
http://imgur.com/a/5WvsA
But I want multi-page reports like the Junit plugins on this video:
https://www.youtube.com/watch?v=lWw9AQqUAGU&t=174s (2:56)
How to make a Jenkins plugin that can display reports on multiple pages?
If you want to go through the JUnit Plugin code below is the starting point to dig into it.
TestResultAction
Refer the below link for an article for you to start.
jenkins-plugin-development
I have accomplished this by utilizing ANT build scripts which generate HTML report files after running all of my JUnits.
You could simply publish JUnit results (represented in HTML files) to a public_html directory on a web server which can then be accessed via web browser, displayed on Jenkins dashboards via iframe, etc
Just add this plugin and publish the JUnit results.
I got a brand new Jenkins machine running on Linux Ubuntu. I use HTML Publisher Plugin to publish my html reports. I also use Jsystem to invoke the test scenario.
Jenkins 1.643
Html Publisher Plugin 1.10
At the end of the test when open the latest html report from the project main page I get this error:
Checksum mismatch
The checksum of the current wrapper file (0dd0c5ec07dff1d7179f03b5deb290e96ac68f8c) does not match the recorded checksum (090f21ac5f8c4b0eed9e789145a2fe2a6134c900). This indicates a possible security issue, therefore Jenkins will not serve this file. You can access the archived HTML files here.
I have checked existence of file and permissions. If I open the report from the job page then everything works.
UPDATE:
When I open the report from the job page I have no CSS and many errors.
Looks like a security issue.
UPDATE 2:
CSS and Javascript are back, Jenkins had an update on their Content Security Policy. Added args to the Jenkins startup scripts. First issue is still on. :(
It is a bug in that version of the HTML publisher plug in. The bug happens if you have more than one report in your job, mark the publishing option: 'Keep past HTML reports' and then click on the second report.
https://issues.jenkins-ci.org/browse/JENKINS-32281
Solution in https://jenkins.ci.cloudbees.com/job/plugins/job/htmlpublisher-plugin/61/.
Solution is released as 1.11 of the plug in.
it worked for me: Blocked script execution in <URL>. because the document's frame is sandboxed and the 'allow-scripts' permission is not set
System.setProperty("hudson.model.DirectoryBrowserSupport.CSP", "")
How to email the reports created by ReportNG using Jenkins?
I have done ReportNG set-up which is perfectly giving the reports to me and I have integrated my suite with Jenkins. But I don't know how to send the reports created by ReportNg as mail via Jenkins. Because, only if we have the entire html folder, the ReportNG works and able to see html report since there are dependencies in the ReportNG so I have to zip and send the entire html folder to see the perfect result.
Note : I am using Emailable-Ext plugin in Jenkins.
You can get the report links from your jenkins server where the reports are saved. And just email the link to the stakeholders, instead of emailing entire report.
Also, you can try jenkins plugins to automatically move the reports to some other machine/directory for future purpose (if needed) and email the links.
After choosing "Add post build action" and selecting "Publish HTML Reports" the htmlpublisher plugin displays the table header fields (html directory to archive, index pages, report title, keep past html reports) but does not display the fields to enter the data. Directly beneath the table header fields the Add and Delete buttons are displayed. I'm hoping someone has seen this behavior before and found a fix.
I'm running Jenkins on ubuntu 12.04. Other than not being able to publish html reports Jenkins is working and building jobs from SVN. No errors are reported in the Jenkins log. I initially was running Jenkins 1.424 when I noticed the problem (new install, so html publisher never used before). So I updated Jenkins to version 1.474 but the problem continued. I have removed and re-installed Jenkins, same results.
Thank you for your ideas and suggestions.
It looks like this bug has been noted: https://issues.jenkins-ci.org/browse/JENKINS-14491
And apparently: "Reverting to Jenkins 1.473 while keeping the plugin to 1.0 works."
This is how the plugin works...
you should create your html separately - let's say you created a folder named "MyReport" that contains a lot of html files in it, and the "index" html file is index.html.
on the "Publish Html Report" fields you will have to fill the following:
html directory to archive = MyReport
index pages = index.html
report title = My Report Title
and then you will have a link for that report from Jenkins UI