Package hudson.plugins.junitattachments
Class AttachmentPublisher
java.lang.Object
hudson.model.AbstractDescribableImpl<hudson.tasks.junit.TestDataPublisher>
hudson.tasks.junit.TestDataPublisher
hudson.plugins.junitattachments.AttachmentPublisher
- All Implemented Interfaces:
ExtensionPoint,Describable<hudson.tasks.junit.TestDataPublisher>
public class AttachmentPublisher
extends hudson.tasks.junit.TestDataPublisher
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncontributeTestData(Run<?, ?> build, FilePath workspace, Launcher launcher, TaskListener listener, hudson.tasks.junit.TestResult testResult) static FilePathgetAttachmentPath(FilePath root, String className, String testName) static FilePathgetAttachmentPath(Run<?, ?> build) static StringgetStorageName(String name) The name of the directory that holds the attachments of the given test case.booleanbooleanvoidsetShowAttachmentsAtClassLevel(Boolean showAttachmentsAtClassLevel) voidsetShowAttachmentsInStdOut(Boolean showAttachmentsInStdOut) Methods inherited from class hudson.tasks.junit.TestDataPublisher
all, getTestDataMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface hudson.model.Describable
getDescriptor
-
Constructor Details
-
AttachmentPublisher
@DataBoundConstructor public AttachmentPublisher()
-
-
Method Details
-
isShowAttachmentsAtClassLevel
public boolean isShowAttachmentsAtClassLevel() -
isShowAttachmentsInStdOut
public boolean isShowAttachmentsInStdOut() -
setShowAttachmentsAtClassLevel
-
setShowAttachmentsInStdOut
-
getAttachmentPath
-
getAttachmentPath
-
getStorageName
The name of the directory that holds the attachments of the given test case.Attachments are stored under a sanitised form of the name, so any URL pointing at them has to be built from the same sanitised form rather than from the raw name.
- Parameters:
name- the raw test case name- Returns:
- the directory name used to store its attachments
-
contributeTestData
public AttachmentPublisher.Data contributeTestData(Run<?, ?> build, FilePath workspace, Launcher launcher, TaskListener listener, hudson.tasks.junit.TestResult testResult) throws IOException, InterruptedException- Overrides:
contributeTestDatain classhudson.tasks.junit.TestDataPublisher- Throws:
IOExceptionInterruptedException
-