Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-72802

attachments don't work when report in subfolder

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • tap-plugin
    • None
    • Jenkins 2.414.2, TAP Plugin 2.3, JUnit Plugin Version1259.v65ffcef24a_88

      When the tap report file resides in the root of the workspace, attachments work fine. If the report file is in a subfolder, then trying to access an attachment leads to an error 'Couldn't read FilePath.'.

      Minimal broken pipeline file (deleting 'folder/', then attachments can be downloaded successfully):

      pipeline {
          agent {
              label 'linux'
          }
          stages {
              stage('testing tap') {
                  steps {
                      writeFile(file: "folder/results.tap", text: """TAP version 13
      # Started 2024-03-02T08:03:20
      1..3
      not ok 1 toto
        ---
        duration_ms: 1
        message: "Failed to validate 'outexpect' (#1: blabla)"
        extensions:
         Files:
          out_1.txt:
           File-Size: 6
           File-Name: out_1.txt
           File-Type: text/plain
           File-Content: aGVsbG8K
        ...
      ok 3 tutu2
        ---
        duration_ms: 1
        ...
      # Finished 2024-03-02T08:03:20""")
                      step([$class: "TapPublisher", testResults: 'folder/**.tap'])
                      archiveArtifacts artifacts: 'folder/**.tap', fingerprint: true // this step is necessary, since tap plugin doesn't archive the report automatically
                  }
              }
          }
      } 

      Also, for the test results, the request for the hover never comes back, we haven't found a way to get this to work (see screenshot)

            kinow Bruno P. Kinoshita
            fschloesser Franziska Schlösser
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: