Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
cstamas committed Jan 8, 2025
1 parent 80b0414 commit 6cffd9a
Show file tree
Hide file tree
Showing 129 changed files with 245 additions and 206 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public void testitMNG0870() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("project/target");
verifier.deleteArtifacts("org.apache.maven.its.mng0870");
verifier.deleteArtifacts("org.apache.maven.its.mng0870", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public void testit() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng0947");
verifier.deleteArtifacts("org.apache.maven.its.mng0947", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public void testitMNG0956() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng0956");
verifier.deleteArtifacts("org.apache.maven.its.mng0956", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@ public void testitMNG1021() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("repo");
verifier.deleteArtifacts("org.apache.maven.its.mng1021");
verifier.deleteArtifacts("org.apache.maven.its.mng1021", null);
verifier.addCliArgument("-Dmaven.consumer.pom=false");
verifier.addCliArgument("initialize");
verifier.execute();
verifier.verifyErrorFreeLog();

verifier.verifyArtifactPresent("org.apache.maven.its.mng1021", "test", "1-SNAPSHOT", "pom");
verifier.verifyArtifactPresent("org.apache.maven.its.mng1021", "test", "1-SNAPSHOT", "jar");
verifier.verifyArtifactPresent("org.apache.maven.its.mng1021", "test", "1-SNAPSHOT", "pom", null);
verifier.verifyArtifactPresent("org.apache.maven.its.mng1021", "test", "1-SNAPSHOT", "jar", null);

String dir = "repo/org/apache/maven/its/mng1021/test/";
String snapshot = getSnapshotVersion(new File(testDir, dir + "1-SNAPSHOT"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public void testitMNG1088() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("client/target");
verifier.deleteArtifacts("org.apache.maven.its.mng1088");
verifier.deleteArtifacts("org.apache.maven.its.mng1088", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ private void testit(String project) throws Exception {
Verifier verifier = newVerifier(new File(testDir, project).getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng1142");
verifier.deleteArtifacts("org.apache.maven.its.mng1142", "maven-core-it");
verifier.addCliArgument("-s");
verifier.addCliArgument("settings.xml");
verifier.filterFile("../settings-template.xml", "settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void testitMNG1233() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.it0083");
verifier.deleteArtifacts("org.apache.maven.its.it0083", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void testitMNG1323() throws Exception {
verifier.deleteDirectory("a/target");
verifier.deleteDirectory("b/target");
verifier.deleteDirectory("c/target");
verifier.deleteArtifacts("org.apache.maven.its.mng1323");
verifier.deleteArtifacts("org.apache.maven.its.mng1323", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public void testitMNG1412() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng1412");
verifier.deleteArtifacts("org.apache.maven.its.mng1412", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void testitMNG1703() throws Exception {
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng1703");
verifier.deleteArtifacts("org.apache.maven.its.mng1703", "maven-core-it");
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,15 @@ public void testit() throws Exception {
// phase 1: deploy a new snapshot, this should update the metadata despite its future timestamp
Verifier verifier = newVerifier(new File(testDir, "dep").getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng1751");
verifier.deleteArtifacts("org.apache.maven.its.mng1751", "maven-core-it");
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();

// phase 2: resolve snapshot, if the previous deployment didn't update the metadata, we get the wrong file
verifier = newVerifier(new File(testDir, "test").getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng1751");
verifier.deleteArtifacts("org.apache.maven.its.mng1751", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public void testitDirectVsIndirect() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng1895");
verifier.deleteArtifacts("org.apache.maven.its.mng1895", "maven-core-it");
verifier.deleteDirectory("target");
verifier.addCliArgument("-s");
verifier.addCliArgument("settings.xml");
Expand Down Expand Up @@ -217,7 +217,7 @@ private Verifier run(String scopeB, String scopeA) throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng1895");
verifier.deleteArtifacts("org.apache.maven.its.mng1895", "maven-core-it");
verifier.deleteDirectory("target");
verifier.addCliArgument("-s");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public void testitMNG2045() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("test-user/target");
verifier.deleteArtifacts("org.apache.maven.its.mng2045");
verifier.deleteArtifacts("org.apache.maven.its.mng2045", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public void testitInheritedIdFields() throws Exception {

Verifier verifier = newVerifier(projectDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2068");
verifier.deleteArtifacts("org.apache.maven.its.mng2068", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand All @@ -68,7 +68,7 @@ public void testitExplicitIdFields() throws Exception {

Verifier verifier = newVerifier(projectDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2068");
verifier.deleteArtifacts("org.apache.maven.its.mng2068", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand All @@ -86,7 +86,7 @@ public void testitComplex() throws Exception {

Verifier verifier = newVerifier(projectDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2068");
verifier.deleteArtifacts("org.apache.maven.its.mng2068", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,16 @@ public void testit() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2098");
verifier.deleteArtifacts("org.apache.maven.its.mng2098", "maven-core-it-1");
verifier.deleteArtifacts("org.apache.maven.its.mng2098", "maven-core-it-2");
verifier.deleteArtifacts("org.apache.maven.its.mng2098", "maven-core-it-3");
verifier.addCliArgument("-s");
verifier.addCliArgument("settings.xml");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();

verifier.verifyArtifactPresent("org.apache.maven.its.mng2098", "dep", "0.1", "jar");
verifier.verifyArtifactPresent("org.apache.maven.its.mng2098", "dep", "0.1", "jar", "maven-core-it-1");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public void testitMNG2123() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2123");
verifier.deleteArtifacts("org.apache.maven.its.mng2123", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public void testitMNG2130() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.mng2130");
verifier.deleteArtifacts("org.apache.maven.mng2130", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void testit() throws Exception {
verifier.setAutoclean(false);
verifier.deleteDirectory("plugin/target");
verifier.deleteDirectory("project/target");
verifier.deleteArtifacts("org.apache.maven.its.mng2135");
verifier.deleteArtifacts("org.apache.maven.its.mng2135", null);
verifier.addCliArgument("package");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public void testitMNG2174() throws Exception {
Verifier verifier = newVerifier(new File(testDir, "sub").getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2174");
verifier.deleteArtifacts("org.apache.maven.its.mng2174", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public void testitMNG2196() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2196");
verifier.deleteArtifacts("org.apache.maven.its.mng2196", null);

if (matchesVersionRange("(,3.0-alpha-1)")) {
verifier.addCliArgument("validate");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public void testit() throws Exception {
verifier.setAutoclean(false);
verifier.deleteDirectory("mod-a/target");
verifier.deleteDirectory("mod-b/target");
verifier.deleteArtifacts("org.apache.maven.its.mng2222");
verifier.deleteArtifacts("org.apache.maven.its.mng2222", null);
verifier.addCliArgument("compile");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void testitMNG2228() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2228");
verifier.deleteArtifacts("org.apache.maven.its.mng2228", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public void testitMNG2277() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2277");
verifier.deleteArtifacts("org.apache.maven.its.mng2277", null);
verifier.addCliArgument("org.apache.maven.its.plugins:maven-it-plugin-all:aggregator-dependencies");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ public void testit() throws Exception {
try {
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2305");
verifier.deleteArtifacts("org.apache.maven.its.mng2305", "http");
verifier.deleteArtifacts("org.apache.maven.its.mng2305", "https");
Map<String, String> filterProps = verifier.newDefaultFilterMap();
filterProps.put("@proxy.http@", Integer.toString(httpPort));
filterProps.put("@proxy.https@", Integer.toString(proxyPort));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,20 @@ public void testit() throws Exception {
verifier.setAutoclean(false);
verifier.deleteDirectory("utf-8/target");
verifier.deleteDirectory("latin-1/target");
verifier.deleteArtifacts("org.apache.maven.its.mng2362");
verifier.deleteArtifacts("org.apache.maven.its.mng2362", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();

File pomFile;

pomFile = new File(verifier.getArtifactPath("org.apache.maven.its.mng2362", "utf-8", "0.1", "pom"));
pomFile = new File(verifier.getArtifactPath("org.apache.maven.its.mng2362", "utf-8", "0.1", "pom", null));
assertPomUtf8(pomFile);

pomFile = new File(testDir, "utf-8/target/repo/org/apache/maven/its/mng2362/utf-8/0.1/utf-8-0.1.pom");
assertPomUtf8(pomFile);

pomFile = new File(verifier.getArtifactPath("org.apache.maven.its.mng2362", "latin-1", "0.1", "pom"));
pomFile = new File(verifier.getArtifactPath("org.apache.maven.its.mng2362", "latin-1", "0.1", "pom", null));
assertPomLatin1(pomFile);

pomFile = new File(testDir, "latin-1/target/repo/org/apache/maven/its/mng2362/latin-1/0.1/latin-1-0.1.pom");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,13 @@ public void testit() throws Exception {
verifier.filterFile("settings-template.xml", "settings.xml", properties);

verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2387");
verifier.deleteArtifacts("org.apache.maven.its.mng2387", "maven-core-it");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();

verifier.verifyArtifactPresent("org.apache.maven.its.mng2387", "a", "0.1", "jar");
verifier.verifyArtifactPresent("org.apache.maven.its.mng2387", "a", "0.1", "jar", "maven-core-it");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ public void testitMNG2432() throws Exception {
Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2432.pom");
verifier.deleteArtifacts("org.apache.maven.its.mng2432.settings");
verifier.deleteArtifacts("org.apache.maven.its.mng2432.pom", "maven-core-it");
verifier.deleteArtifacts("org.apache.maven.its.mng2432.settings", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public void testit() throws Exception {
verifier = newVerifier(new File(testDir, "dep-a").getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
verifier.deleteArtifacts("org.apache.maven.its.mng2486");
verifier.deleteArtifacts("org.apache.maven.its.mng2486", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();
Expand All @@ -75,7 +75,8 @@ public void testit() throws Exception {
verifier.setAutoclean(false);
verifier.deleteDirectory("target");
// enforce remote resolution
verifier.deleteArtifacts("org.apache.maven.its.mng2486");
verifier.deleteArtifacts("org.apache.maven.its.mng2486", null);
verifier.deleteArtifacts("org.apache.maven.its.mng2486", "maven-core-it");
verifier.filterFile("settings-template.xml", "settings.xml");
verifier.addCliArgument("--settings");
verifier.addCliArgument("settings.xml");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ public void testitMNG2668() throws Exception {

Verifier verifier = newVerifier(testDir.getAbsolutePath());
verifier.setAutoclean(false);
verifier.deleteArtifacts("org.apache.maven.its.mng2668");
verifier.deleteArtifacts("org.apache.maven.its.mng2668", null);
verifier.addCliArgument("validate");
verifier.execute();
verifier.verifyErrorFreeLog();

verifier.verifyArtifactPresent("org.apache.maven.its.mng2668", "project", "1.0-SNAPSHOT", "jar");
verifier.verifyArtifactPresent("org.apache.maven.its.mng2668", "tools", "1.0-SNAPSHOT", "jar");
verifier.verifyArtifactPresent("org.apache.maven.its.mng2668", "project", "1.0-SNAPSHOT", "jar", null);
verifier.verifyArtifactPresent("org.apache.maven.its.mng2668", "tools", "1.0-SNAPSHOT", "jar", null);
}
}
Loading

0 comments on commit 6cffd9a

Please sign in to comment.