use of org.jetbrains.jps.model.artifact.JpsArtifact in project intellij-community by JetBrains.
the class ArtifactBuilderTest method testTwoDirsInArchive.
public void testTwoDirsInArchive() {
final String dir1 = PathUtil.getParentPath(PathUtil.getParentPath(createFile("dir1/a/x.txt")));
final String dir2 = PathUtil.getParentPath(PathUtil.getParentPath(createFile("dir2/a/y.txt")));
final JpsArtifact a = addArtifact(root().archive("a.jar").dirCopy(dir1).dirCopy(dir2).dir("a").fileCopy(createFile("z.txt")));
buildAll();
assertOutput(a, fs().archive("a.jar").dir("a").file("x.txt").file("y.txt").file("z.txt"));
}
use of org.jetbrains.jps.model.artifact.JpsArtifact in project intellij-community by JetBrains.
the class ArtifactBuilderTest method testArtifactContainingSelfIncludingArtifact.
public void testArtifactContainingSelfIncludingArtifact() {
JpsArtifact c = addArtifact("c", root());
final JpsArtifact a = addArtifact("a", root().artifact(c));
LayoutElementTestUtil.addArtifactToLayout(a, a);
final JpsArtifact b = addArtifact("b", root().artifact(a));
buildArtifacts(c);
assertBuildFailed(b);
assertBuildFailed(a);
}
use of org.jetbrains.jps.model.artifact.JpsArtifact in project intellij-community by JetBrains.
the class ArtifactBuilderTest method testSelfIncludingArtifact.
public void testSelfIncludingArtifact() {
final JpsArtifact a = addArtifact("a", root());
LayoutElementTestUtil.addArtifactToLayout(a, a);
assertBuildFailed(a);
}
use of org.jetbrains.jps.model.artifact.JpsArtifact in project intellij-community by JetBrains.
the class ArtifactBuilderTest method testIncludedArtifact.
public void testIncludedArtifact() {
final JpsArtifact included = addArtifact("included", root().fileCopy(createFile("aaa.txt")));
final JpsArtifact a = addArtifact(root().dir("dir").artifact(included).end().fileCopy(createFile("bbb.txt")));
buildAll();
assertOutput(included, fs().file("aaa.txt"));
assertOutput(a, fs().dir("dir").file("aaa.txt").end().file("bbb.txt"));
}
use of org.jetbrains.jps.model.artifact.JpsArtifact in project intellij-community by JetBrains.
the class ArtifactBuilderTest method testExtractDirectory.
public void testExtractDirectory() {
final JpsArtifact a = addArtifact("a", root().dir("dir").extractedDir(getJUnitJarPath(), "/junit/textui/"));
buildAll();
assertOutput(a, fs().dir("dir").file("ResultPrinter.class").file("TestRunner.class"));
}
Aggregations