3

I have created a test job in jenkins and used html report publisher plugin to send the html report out puts (which is under project-root-directory/reports/htmls folder) back to the master server.

As the test jobs rerun the html report out puts gets changed (before 4 passed now its 1 fail 3 passed). But the html publisher still shows the old report(4 passed) if I open the job and click the HTML Report link .

Below screenshot is the old report which the master still displays:

enter image description here

But Actually it should have been like below :(which the tes job correctly creates inside the jenkins worksapce project dir)

enter image description here

Advance thanks for any input on fixing it so that the html report publisher plugin shows the updated test outouts (the second screenshot instead of the first one ).

Som
  • 4,618
  • 4
  • 29
  • 32
  • Hi Som, did you resolve this? I'm getting the same behavior and unable to figure out why. I noticed that the build pages do have a correct log displayed. – Eldad Assis Aug 13 '14 at 08:08

2 Answers2

1

I faced a similar problem.

In HTML Publisher plugin, under Publisher Options, select/check the option Always link to last build.

This will make sure that it always shows the latest one.

Warren Sergent
  • 2,542
  • 4
  • 36
  • 42
Mathangi
  • 11
  • 1
0

Are you providing absolute path value for HTML Directory to archive in Post-Build configurations section? If so, consider moving this directory path something to dynamic which is unique for each test run.

I'm suspecting HTML report publisher is showing up the same report for every build, because for each build it reads from the same file path that you've provided.

bram
  • 1,268
  • 2
  • 12
  • 20
  • Thanks Bharathi fr ur input but my doubt is.....The workspace (checked out code ) repository in the slave machine which includes report files is cleaned each time the job is run, so if the html publisher points to the absolute path also to get the reports it should have fetched the updated report htmls generated from the latest run . – Som Jun 18 '14 at 07:57
  • I don't think it will be cleaned up by Jenkins. Perhaps, you might have enabled workspace cleaner before the build starts. – bram Jun 24 '14 at 09:02
  • the report folder gets cleaned in the project workspace each time.. when the job is run.. as part the ant target "clean" operation so that it holds the latest reports. – Som Jun 25 '14 at 12:26