Dynamically populate repositories used in Ant/Maven integration tests
Update build scripts and tests so that repository settings are copied dynamically from the build. See gh-42333
This commit is contained in:
@@ -46,8 +46,16 @@ task syncTestRepository(type: Sync) {
|
||||
}
|
||||
}
|
||||
|
||||
task copyAntSources(type: Copy) {
|
||||
from project.layout.projectDirectory
|
||||
include "*.xml"
|
||||
into "${buildDir}/antbuild"
|
||||
filter(springRepoistoryTransformers.ant())
|
||||
}
|
||||
|
||||
task antRun(type: JavaExec) {
|
||||
dependsOn syncTestRepository, configurations.antDependencies
|
||||
workingDir "${buildDir}/antbuild"
|
||||
dependsOn syncTestRepository, copyAntSources, configurations.antDependencies
|
||||
classpath = configurations.antDependencies;
|
||||
mainClass = "org.apache.tools.ant.launch.Launcher"
|
||||
args = [ "clean", "build" ]
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
</target>
|
||||
|
||||
<target name="compile" depends="init" description="compile">
|
||||
<javac srcdir="src/main/java" destdir="build/ant/classes" classpathref="compile.classpath" fork="true" includeantruntime="false" source="8" target="8" compiler="javac1.8"/>
|
||||
<javac srcdir="${projectDir}/src/main/java" destdir="build/ant/classes" classpathref="compile.classpath" fork="true" includeantruntime="false" source="8" target="8" compiler="javac1.8"/>
|
||||
</target>
|
||||
|
||||
<target name="clean" description="cleans all created files/dirs">
|
||||
|
||||
@@ -9,8 +9,7 @@
|
||||
<ivy pattern="${projectDir}/build/test-repository/[organisation]/[module]/[revision]/[module]-[revision].pom" />
|
||||
</filesystem>
|
||||
<ibiblio name="ibiblio" m2compatible="true" />
|
||||
<ibiblio name="spring-milestones" m2compatible="true" root="https://repo.spring.io/milestone" />
|
||||
<ibiblio name="spring-snapshots" m2compatible="true" root="https://repo.spring.io/snapshot" />
|
||||
<!-- {spring.mavenRepositories} -->
|
||||
</chain>
|
||||
</resolvers>
|
||||
</ivysettings>
|
||||
|
||||
Reference in New Issue
Block a user