### Question:
ArtifactArchiver extends Recorder { @Override public boolean needsToRun(Result buildResult) { return buildResult.isBetterThan(Result.ABORTED); } @Deprecated  ArtifactArchiver(String artifacts, String excludes, boolean latestOnly); @Deprecated  ArtifactArchiver(String artifacts, String excludes, boolean latestOnly, String compressionType); @DataBoundConstructor  ArtifactArchiver(String artifacts, String excludes, boolean latestOnly, String compressionType,
            boolean autoValidateFileMask); @Override boolean needsToRun(Result buildResult); String getArtifacts(); String getExcludes(); boolean isLatestOnly(); boolean isAutoValidateFileMask(); FilePath.TarCompression getCompressionType(); void setCompressionType(String compression); @Override boolean perform(AbstractBuild<?, ?> build, Launcher launcher, BuildListener listener); @Override boolean prebuild(AbstractBuild<?, ?> build, BuildListener listener); BuildStepMonitor getRequiredMonitorService(); static volatile DescriptorImpl DESCRIPTOR; }### Answer:
@Bug(4505) @Test public void testNeedsToRunAborted(){ assertEquals(expectedResult, publisher.needsToRun(buildResult)); }