@@ -26,41 +26,24 @@ idea.module.testSourceDirs += sourceSets.jarFileTest.allSource.srcDirs
2626configurations {
2727 baseline
2828 shaded
29- [runtime , compileOnly, testCompile]* . extendsFrom shaded
29+ [api , compileOnly, testCompile]* . extendsFrom shaded
3030}
3131
3232shadowJar {
3333 configurations = [project. configurations. shaded]
3434
3535 mergeServiceFiles()
3636
37- exclude ' org/newsclub/**'
38-
3937 [
4038 ' META-INF/NOTICE' ,
4139 ' META-INF/NOTICE.txt' ,
4240 ' META-INF/LICENSE' ,
4341 ' META-INF/LICENSE.txt' ,
44- ' META-INF/DEPENDENCIES' ,
4542 ' META-INF/maven/' ,
4643 ' META-INF/proguard/' ,
4744 ' META-INF/versions/*/module-info.class' ,
48- ' META-INF/services/README.md' ,
49- ' META-INF/services/com.fasterxml.jackson.core.*' ,
50- ' META-INF/services/com.github.dockerjava.api.command.*' ,
51- ' META-INF/services/javax.ws.rs.ext.*' ,
5245 ' META-INF/services/java.security.Provider' ,
53- ' mozilla/public-suffix-list.txt' ,
54- ' module-info.class' ,
5546 ]. each { exclude(it) }
56-
57- project. afterEvaluate {
58- dependencies {
59- for (id in project. configurations. compile. resolvedConfiguration. resolvedArtifacts* . moduleVersion* . id) {
60- exclude(dependency(" ${ id.group} :${ id.name} " ))
61- }
62- }
63- }
6447}
6548
6649task jarFileTest (type : Test ) {
@@ -169,16 +152,16 @@ dependencies {
169152 exclude group : " *" , module : " *"
170153 }
171154
172- compile ' junit:junit:4.12'
173- compile ' org.slf4j:slf4j-api:1.7.30'
155+ api ' junit:junit:4.12'
156+ api ' org.slf4j:slf4j-api:1.7.30'
174157 compileOnly ' org.jetbrains:annotations:20.1.0'
175158 testCompileClasspath ' org.jetbrains:annotations:20.0.0'
176- compile ' org.apache.commons:commons-compress:1.20'
177- compile (' org.rnorth.duct-tape:duct-tape:1.0.8' ) {
159+ api ' org.apache.commons:commons-compress:1.20'
160+ api (' org.rnorth.duct-tape:duct-tape:1.0.8' ) {
178161 exclude(group : ' org.jetbrains' , module : ' annotations' )
179162 }
180163
181- compile " com.github.docker-java:docker-java-api:3.2.8"
164+ api " com.github.docker-java:docker-java-api:3.2.8"
182165
183166 shaded (' com.github.docker-java:docker-java-core:3.2.8' ) {
184167 exclude(group : ' com.github.docker-java' , module : ' docker-java-api' )
@@ -195,7 +178,7 @@ dependencies {
195178 exclude(group : ' org.slf4j' )
196179 }
197180
198- compile ' com.github.docker-java:docker-java-transport-zerodep:3.2.8'
181+ api ' com.github.docker-java:docker-java-transport-zerodep:3.2.8'
199182
200183 shaded " org.yaml:snakeyaml:1.27"
201184
@@ -205,24 +188,31 @@ dependencies {
205188 exclude(group : ' org.slf4j' )
206189 }
207190
208- testCompile ' org.apache.httpcomponents:httpclient:4.5.9'
209- testCompile ' redis.clients:jedis:3.6.0'
210- testCompile ' com.rabbitmq:amqp-client:5.9.0'
211- testCompile ' org.mongodb:mongo-java-driver:3.12.7'
191+ testImplementation ' org.apache.httpcomponents:httpclient:4.5.9'
192+ testImplementation ' redis.clients:jedis:3.6.0'
193+ testImplementation ' com.rabbitmq:amqp-client:5.9.0'
194+ testImplementation ' org.mongodb:mongo-java-driver:3.12.7'
212195
213- testCompile (' org.mockito:mockito-core:3.10.0' ) {
196+ testImplementation (' org.mockito:mockito-core:3.10.0' ) {
214197 exclude(module : ' hamcrest-core' )
215198 }
216199 // Synthetic JAR used for MountableFileTest and DirectoryTarResourceTest
217- testCompile files(' testlib/repo/fakejar/fakejar/0/fakejar-0.jar' )
200+ testImplementation files(' testlib/repo/fakejar/fakejar/0/fakejar-0.jar' )
218201
219- testCompile ' org.rnorth.visible-assertions:visible-assertions:2.1.2'
220- testCompile ' org.assertj:assertj-core:3.18.1'
221- testCompile project(' :test-support' )
202+ testImplementation ' org.rnorth.visible-assertions:visible-assertions:2.1.2'
203+ testImplementation ' org.assertj:assertj-core:3.18.1'
204+ testImplementation project(' :test-support' )
222205
223206 jarFileTestCompileOnly " org.projectlombok:lombok:${ lombok.version} "
224207 jarFileTestAnnotationProcessor " org.projectlombok:lombok:${ lombok.version} "
225- jarFileTestCompile ' junit:junit:4.12'
226- jarFileTestCompile ' org.assertj:assertj-core:3.18.1'
227- jarFileTestCompile ' org.ow2.asm:asm-debug-all:5.2'
208+ jarFileTestImplementation ' junit:junit:4.12'
209+ jarFileTestImplementation ' org.assertj:assertj-core:3.18.1'
210+ jarFileTestImplementation ' org.ow2.asm:asm-debug-all:5.2'
228211}
212+
213+ tasks. generatePomFileForMavenJavaPublication. finalizedBy(
214+ tasks. register(' checkPOMdependencies' , org.testcontainers.build.ComparePOMWithLatestReleasedTask ) {
215+ ignore = [
216+ ]
217+ }
218+ )
0 commit comments