public void testUnpackOverWriteSnapshot() throws Exception { stubFactory.setCreateFiles(true); Artifact artifact = stubFactory.getSnapshotArtifact(); artifact.getFile().setLastModified(System.currentTimeMillis() - 2000); ArtifactItem item = new ArtifactItem(artifact); List<ArtifactItem> list = new ArrayList<ArtifactItem>(1); list.add(item); mojo.setArtifactItems(list); mojo.setOverWriteIfNewer(false); mojo.setOverWriteReleases(false); mojo.setOverWriteSnapshots(true); mojo.execute(); assertUnpacked(item, true); }