I have a build.gradle
like this:
apply plugin: 'java'
dependencies{
compile 'junit:junit:4.12'
}
and when I run gradle dependencies
I get:
------------------------------------------------------------
Root project
------------------------------------------------------------
apiElements - API elements for main. (n)
No dependencies
archives - Configuration for archive artifacts.
No dependencies
compile - Dependencies for source set 'main' (deprecated, use 'implementation ' instead).
\--- junit:junit:4.12 FAILED
compileClasspath - Compile classpath for source set 'main'.
\--- junit:junit:4.12 FAILED
compileOnly - Compile only dependencies for source set 'main'.
No dependencies
default - Configuration for default artifacts.
\--- junit:junit:4.12 FAILED
implementation - Implementation only dependencies for source set 'main'. (n)
No dependencies
runtime - Runtime dependencies for source set 'main' (deprecated, use 'runtimeOnly ' instead).
\--- junit:junit:4.12 FAILED
runtimeClasspath - Runtime classpath of source set 'main'.
\--- junit:junit:4.12 FAILED
runtimeElements - Elements of runtime for main. (n)
No dependencies
runtimeOnly - Runtime only dependencies for source set 'main'. (n)
No dependencies
testCompile - Dependencies for source set 'test' (deprecated, use 'testImplementation ' instead).
\--- junit:junit:4.12 FAILED
testCompileClasspath - Compile classpath for source set 'test'.
\--- junit:junit:4.12 FAILED
testCompileOnly - Compile only dependencies for source set 'test'.
No dependencies
testImplementation - Implementation only dependencies for source set 'test'. (n)
No dependencies
testRuntime - Runtime dependencies for source set 'test' (deprecated, use 'testRuntimeOnly ' instead).
\--- junit:junit:4.12 FAILED
testRuntimeClasspath - Runtime classpath of source set 'test'.
\--- junit:junit:4.12 FAILED
testRuntimeOnly - Runtime only dependencies for source set 'test'. (n)
No dependencies
Why are there the FAILED dependencies? And what does deprecated, use 'implementation' instead mean?
I also used:
testImplementation 'junit:junit:4.12'
but the same command returns still FAILED part: testCompileClasspath
and testRuntimeClasspath
.
Why is this happening?