Skip to content

Commit

Permalink
upgraded some libs
Browse files Browse the repository at this point in the history
  • Loading branch information
wipu committed Aug 9, 2024
1 parent a1c361c commit e945bfe
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ private IwantSrcModuleSpex module(String fullName) {
* @return
*/
private JavaModule antLauncher = binModule("org.apache.ant", "ant-launcher",
"1.10.7");
"1.10.14");

private JavaModule asm = JavaBinModule.providing(FromRepository
.repo1MavenOrg().group("asm").name("asm").version("3.2").jar())
Expand Down Expand Up @@ -98,10 +98,10 @@ private IwantSrcModuleSpex module(String fullName) {
.name("jaxen").version("1.1.4").jar())
.end();

private JavaModule junit = JavaBinModule
.providing(FromRepository.repo1MavenOrg().group("junit")
.name("junit").version("4.8.2").jar())
.end();
private final JavaBinModule hamcrestCore = binModule("org/hamcrest",
"hamcrest-core", "1.3");
private final JavaModule junit = binModule("junit", "junit", "4.13.2",
hamcrestCore);

// TODO document dependency to asm, jaxen
private JavaModule pmd = JavaBinModule.providing(FromRepository
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,14 +112,14 @@ public void testContentDescriptorAndIngredients() {
+ " scala-compiler-2.12.13.jar\n" + "i:scala-library:\n"
+ " scala-library-2.12.13.jar\n" + "i:scala-reflect:\n"
+ " scala-reflect-2.12.13.jar\n" + "i:antJar:\n"
+ " ant-1.10.13.jar\n" + "i:antLauncherJar:\n"
+ " ant-launcher-1.10.13.jar\n" + "",
+ " ant-1.10.14.jar\n" + "i:antLauncherJar:\n"
+ " ant-launcher-1.10.14.jar\n" + "",
scalaClasses.contentDescriptor());

assertEquals(
"[src/main/java, src/main/scala, dep, scala-compiler-2.12.13.jar,"
+ " scala-library-2.12.13.jar, scala-reflect-2.12.13.jar,"
+ " ant-1.10.13.jar, ant-launcher-1.10.13.jar]",
+ " ant-1.10.14.jar, ant-launcher-1.10.14.jar]",
scalaClasses.ingredients().toString());
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ private Path antLauncherJar() {
public void testContentDescriptor() {
assertEquals("org.fluentjava.iwant.core.ant.AntGenerated\n"
+ "i:ant-jars:\n " + Iwant.IWANT_USER_DIR
+ "/cached/UnmodifiableUrl/https%3A/%2Frepo1.maven.org/maven2/org/apache/ant/ant/1.10.13/ant-1.10.13.jar\n"
+ "/cached/UnmodifiableUrl/https%3A/%2Frepo1.maven.org/maven2/org/apache/ant/ant/1.10.14/ant-1.10.14.jar\n"
+ "i:script:\n script\n",
AntGenerated.with().name("minimal").antJars(antJar())
.script(Source.underWsroot("script")).end()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public static GnvArtifact<Downloaded> jcommander() {

public static GnvArtifact<Downloaded> junit() {
return FromRepository.repo1MavenOrg().group("junit").name("junit")
.version("4.8.2").jar();
.version("4.13.2").jar();
}

public static GnvArtifact<Downloaded> testng() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,14 @@ public class TestedIwantDependenciesTest extends TestCase {

public void testNamesOfDownloadedTargets() {
// this documents the names, change when upgrading:
assertEquals("ant-1.10.13.jar",
assertEquals("ant-1.10.14.jar",
TestedIwantDependencies.antJar().name());
assertEquals("ant-launcher-1.10.13.jar",
assertEquals("ant-launcher-1.10.14.jar",
TestedIwantDependencies.antLauncherJar().name());
assertEquals("jcommander-1.48.jar",
TestedIwantDependencies.jcommander().name());
assertEquals("junit-4.8.2.jar", TestedIwantDependencies.junit().name());
assertEquals("junit-4.13.2.jar",
TestedIwantDependencies.junit().name());
assertEquals("testng-6.9.4.jar",
TestedIwantDependencies.testng().name());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
public class Iwant2 {

public static final String REPO_MAVEN_ORG = "https://repo1.maven.org/maven2/";
public static final String ANT_VER = "1.10.13";
public static final String ANT_VER = "1.10.14";
private final IwantNetwork network;
private final Iwant iwant;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -886,8 +886,8 @@ public void testSideEffectThatReferencesIwantPlugin() {

assertEquals("ant-plugin-print mutating.\n"
+ "ant-plugin modules: [iwant-plugin-ant,"
+ " mock-iwant-classes, ant-1.10.13.jar,"
+ " ant-launcher-1.10.13.jar]", err.toString());
+ " mock-iwant-classes, ant-1.10.14.jar,"
+ " ant-launcher-1.10.14.jar]", err.toString());
}

private static class WorkspaceWithTarget implements Workspace {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ public void testIwantPluginAntWithDependenciesContainsCorrectModules() {
assertEquals("iwant-plugin-ant", iterator.next().name());
assertSame(iwantApiModule1, iterator.next());
assertSame(iwantApiModule2, iterator.next());
assertEquals("ant-1.10.13.jar", iterator.next().name());
assertEquals("ant-launcher-1.10.13.jar", iterator.next().name());
assertEquals("ant-1.10.14.jar", iterator.next().name());
assertEquals("ant-launcher-1.10.14.jar", iterator.next().name());
}

public void testIwantPluginAntMainClassesHasCorrectCompilationClasspath() {
Expand All @@ -75,7 +75,7 @@ public void testIwantPluginAntMainClassesHasCorrectCompilationClasspath() {

assertSame(iwantApiModule1.mainArtifact(), iterator.next());
assertSame(iwantApiModule2.mainArtifact(), iterator.next());
assertEquals("ant-1.10.13.jar", iterator.next().name());
assertEquals("ant-1.10.14.jar", iterator.next().name());
}

public void testIwantPluginAntMainJavaIsASubdirectoryUnderIwantSources() {
Expand All @@ -96,31 +96,31 @@ public void testIwantPluginPmdWithDependenciesContainsCorrectModules() {
Set<JavaModule> mods = ctx.iwantPlugin().pmd().withDependencies();

assertEquals("[iwant-plugin-pmd, iwant-api-1, iwant-api-2,"
+ " ant-1.10.13.jar, asm-3.2.jar, commons-io-1.3.2.jar,"
+ " ant-1.10.14.jar, asm-3.2.jar, commons-io-1.3.2.jar,"
+ " jaxen-1.1.4.jar, pmd-4.3.jar]", mods.toString());
}

public void testIwantPluginFindbugsWithDependenciesContainsCorrectModules() {
Set<JavaModule> mods = ctx.iwantPlugin().findbugs().withDependencies();

assertEquals("[iwant-plugin-findbugs, iwant-api-1, iwant-api-2,"
+ " commons-io-1.3.2.jar, iwant-plugin-ant, ant-1.10.13.jar,"
+ " ant-launcher-1.10.13.jar]", mods.toString());
+ " commons-io-1.3.2.jar, iwant-plugin-ant, ant-1.10.14.jar,"
+ " ant-launcher-1.10.14.jar]", mods.toString());
}

public void testIwantPluginGithubWithDependenciesContainsCorrectModules() {
Set<JavaModule> mods = ctx.iwantPlugin().github().withDependencies();

assertEquals("[iwant-plugin-github, iwant-api-1, iwant-api-2,"
+ " iwant-plugin-ant, ant-1.10.13.jar,"
+ " ant-launcher-1.10.13.jar]", mods.toString());
+ " iwant-plugin-ant, ant-1.10.14.jar,"
+ " ant-launcher-1.10.14.jar]", mods.toString());
}

public void testIwantPluginWarWithDependenciesContainsCorrectModules() {
Set<JavaModule> mods = ctx.iwantPlugin().war().withDependencies();

assertEquals(
"[iwant-plugin-war, iwant-api-1, iwant-api-2, ant-1.10.13.jar]",
"[iwant-plugin-war, iwant-api-1, iwant-api-2, ant-1.10.14.jar]",
mods.toString());
}

Expand All @@ -129,8 +129,8 @@ public void testIwantPluginJacocoWithDependenciesContainsCorrectModules() {

assertEquals(
"[iwant-plugin-jacoco, iwant-api-1, iwant-api-2,"
+ " iwant-plugin-ant, ant-1.10.13.jar,"
+ " ant-launcher-1.10.13.jar, commons-io-1.3.2.jar]",
+ " iwant-plugin-ant, ant-1.10.14.jar,"
+ " ant-launcher-1.10.14.jar, commons-io-1.3.2.jar]",
mods.toString());
}

Expand Down

0 comments on commit e945bfe

Please sign in to comment.