Scenario: Send an email after the build with the emailable-report.html
.
Am able to achieve the above scenario.
But when the build is completed in jenkins, target
folder or test-output
folder is not updated after build. which means the jenkins workspace is not updating the target
folder or test-output
folder after the build. Rather the Jenkins workspace remains with the code checked out from GIT repository.
I want the jenkins workspace to be updated after the build to email the latest emailable-report.html
.
Script for the sending the email:
def reportPath = build.getWorkspace().child("test-output/emailable-report.html")
msg.setContent(reportPath.readToString(), "text/html")
Help me with this scenario.