Details
-
Type:
Improvement
-
Status: Open (View Workflow)
-
Priority:
Blocker
-
Resolution: Unresolved
-
Component/s: junit-plugin
-
Labels:None
-
Similar Issues:
Description
The JUnit Result Archiver will fail the build if the test result files that match the filemask do not have a very recent modification time. The error message it prints is this:
"Test reports were found but none of them are new. Did tests run?"
This can be inconvenient in several settings; notably, when the clocks on the master and slave fall out of sync, or when the test results were generated by some process that isn't part of the build itself – maybe they were scp'd from somewhere else, for instance. Or for testing the JUnitResultArchiver itself.
In my opinion, the behavior should be changed such that check-for-recent-modifications should be off by default. Additionally, the user should be able to specify a "recent" threshold via a setting.
Attachments
Issue Links
- duplicates
-
JENKINS-5393 Jenkins falsely fails builds due to aggressive up-to-date check on junit artifacts
-
- Open
-
- is duplicated by
-
JENKINS-18148 JUnit Test Result Report Silently Ignores Files With Old Timestamps?
-
- Resolved
-
- is related to
-
JENKINS-9438 Gradle CI builds fail when no test tasks are run
-
- Closed
-
-
JENKINS-47315 No new tests found should be treated as empty results
-
- In Progress
-
- links to
I'm also blocked by this – I use a single Jenkins pipeline job to execute tests (across multiple environments – we want reporting on a per-environment level), and then another job executes which pulls those JUnit results into the workspace, and builds a report. I am encountering this on XMLs that are ~5 seconds "old".
This Powershell script works, but still not the greatest:
$files = Get-ChildItem "${WORKSPACE}" foreach ($i in $files) { $i.LastWriteTime = $(Get-Date) }