12

Im using Jenkins to run UI Testing suites for various xcode projects. Most of the projects shows the 'Test Result Trend' graph with no problem.

However, one of my projects fails to show the graph.

I have run the build a few times found but cannot find any obvious differences between those projects that display the graph and those that dont:

  1. Their configs are setup the same (except for git repo location)
  2. Their console outputs seems to display the same (no mention of errors around populating the graph)
  3. The test-reports/*.xml files all appear in the same valid format

Really at a loss on this one and so thought I would post to see if anyone else has resolved an issue like this before?

Updated more details:

  • Its a Freestyle project
  • Using the xcode plugin
  • Using Junit test result plugin set as 'test-reports/*.xml'
  • When I select Test Results Analyzer the full test results display (i.e. its only the Test Result Trend graph that is failing to appear at all). The graph isn't empty it is simply not shown at all. Also, 'Latest Test Results' link is also missing.
Charlie S
  • 4,366
  • 6
  • 59
  • 97
  • What kind of job is it? How do you publish test results? What step do you use for that? – luka5z Apr 21 '16 at 11:26
  • Luka5z updated the original item to hopefully answer your question. – Charlie S Apr 21 '16 at 12:35
  • This might seem like a dumb question, but did you make sure that you have a post-build action setup in the job to publish junit test results? Maybe the job configurations got inadvertently changed!?! – TheEllis Apr 21 '16 at 12:42
  • Hi Ellis. Yeah all the configurations (including post build actions) are the same in the project that shows the graph and the project that doesnt. Really has me stumped this one :-/ – Charlie S Apr 21 '16 at 13:25
  • @CharlieSeligman Let's try a workaround: Create new job from a copy of working configuration, and change just a Git repository. Check if this fresh job will correctly display Test Trend Results. – luka5z Apr 21 '16 at 15:00
  • @luka5z tried that and afraid the graph didnt appear. – Charlie S Apr 21 '16 at 15:23
  • @CharlieSeligman Try: 1) Update [Dashboard View Plugin](https://wiki.jenkins-ci.org/display/JENKINS/Dashboard+View) 2) Restart Jenkins. If 1) and 2) won't help maybe this problem is related to naming convention. Please read an [article](http://sellotapetest.blogspot.com/2011/08/test-result-trend-not-appearing-in.html) explaining some obscure issue with Test Result Trend. If that won't help you, it's high time to issue Jenkins bug. – luka5z Apr 21 '16 at 15:58

2 Answers2

26

Test Result Trends does not show up on Job page unless you have at least one successful (100% passed) test run. If you have all test runs as failure till date, it will not show.

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Manik Jadhav
  • 387
  • 4
  • 9
9

Little bit late to the party...

"Test Result Trend" will be shown if you have at least one failed and at least one successful test.

That was the case with NUnit plugin in my Jenkins configuration.

Dragan Gorgiev
  • 113
  • 1
  • 5
  • This answers the question perfectly – Ora Jan 24 '18 at 14:40
  • I just ran into this exact scenario - I wonder if anyone has opened a bug/issue against the plugin? I also do not see the 'cucumber reports' option on the left unless there was at least one success within the job (different cucumber-reports plugin, same issue) – Cinderhaze Jul 08 '19 at 19:46
  • 3
    Why do I need to have a failed test in order for the test result trend to show? – trebor Nov 21 '19 at 23:34
  • I ran into this when mstest and nunit were both being used but one of them had zero tests yet. I simply removed nunit test run from the build. Everything was groovy then. – neoscribe Jan 29 '21 at 18:54