121 lines
4.1 KiB
Groovy
121 lines
4.1 KiB
Groovy
plugins {
|
|
id 'java-library'
|
|
id 'maven-publish'
|
|
id 'signing'
|
|
id 'idea'
|
|
}
|
|
|
|
ext {
|
|
buildTarget = rootProject.ext.buildTarget
|
|
}
|
|
|
|
idea {
|
|
module {
|
|
downloadJavadoc = true // defaults to false
|
|
downloadSources = true
|
|
}
|
|
}
|
|
|
|
apply from: "../../chooseBackend.gradle"
|
|
|
|
chipList.each { thisChip ->
|
|
configurations.register("${thisChip}TestImplementation") {
|
|
it.extendsFrom configurations.testImplementation
|
|
it.extendsFrom configurations.implementation
|
|
}
|
|
configurations.register("${thisChip}TestRuntime") {
|
|
it.extendsFrom configurations.testRuntimeOnly
|
|
it.extendsFrom configurations.api
|
|
it.extendsFrom configurations.implementation
|
|
it.extendsFrom configurations.testImplementation
|
|
}
|
|
|
|
tasks.register("${thisChip}Test", Test) {
|
|
it.testClassesDirs = sourceSets.test.output.classesDirs
|
|
it.useJUnitPlatform()
|
|
it.classpath = configurations.getByName("${thisChip}TestRuntime")
|
|
it.classpath += sourceSets.test.output.classesDirs
|
|
it.classpath += sourceSets.main.output.classesDirs
|
|
it.ignoreFailures = true
|
|
it.testLogging {
|
|
events "PASSED", "SKIPPED", "FAILED", "STANDARD_OUT", "STANDARD_ERROR"
|
|
}
|
|
//it.jvmArgs("-Dorg.bytedeco.javacpp.logger.debug=true")
|
|
|
|
// it.debug = true
|
|
}
|
|
|
|
tasks.test.dependsOn "${thisChip}Test"
|
|
}
|
|
|
|
test {
|
|
enabled = false
|
|
}
|
|
|
|
dependencies {
|
|
testImplementation 'org.junit.jupiter:junit-jupiter-params'
|
|
testRuntimeOnly project(":cavis-native:cavis-native-blas")
|
|
testRuntimeOnly project(":cavis-nd4j:cavis-nd4j-common-tests")
|
|
testRuntimeOnly "net.brutex.ai:dl4j-test-resources:1.0.1-SNAPSHOT"
|
|
|
|
|
|
if(withCuda()) {
|
|
cudaTestRuntime platform(project(":cavis-common-platform"))
|
|
cudaTestRuntime project(":cavis-native:cavis-native-jcublas")
|
|
cudaTestRuntime group: "org.bytedeco", name: "openblas"
|
|
cudaTestRuntime group: "org.bytedeco", name: "openblas", classifier: buildTarget
|
|
cudaTestRuntime "org.bytedeco:cuda"
|
|
cudaTestRuntime (project(":cavis-native:cavis-native-lib")) {
|
|
capabilities{
|
|
it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cuda-support:1.0.0-SNAPSHOT"
|
|
}
|
|
}
|
|
}
|
|
|
|
if(withCpu()) {
|
|
cpuTestRuntime project(":cavis-native:cavis-native-cpu")
|
|
cpuTestRuntime group: "org.bytedeco", name: "openblas"
|
|
cpuTestRuntime group: "org.bytedeco", name: "openblas", classifier: buildTarget
|
|
cpuTestRuntime (project(":cavis-native:cavis-native-lib")) {
|
|
capabilities{
|
|
it.requireCapabilities "net.brutex.cavis-native:cavis-native-lib-cpu-support:1.0.0-SNAPSHOT"
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
implementation platform(project(':cavis-common-platform'))
|
|
|
|
implementation project(':cavis-dnn:cavis-dnn-common')
|
|
implementation project(':cavis-dnn:cavis-dnn-api')
|
|
implementation project(":cavis-nd4j:cavis-nd4j-common-tests")
|
|
|
|
implementation 'org.apache.commons:commons-lang3'
|
|
implementation 'commons-io:commons-io'
|
|
implementation "commons-codec:commons-codec"
|
|
implementation 'org.slf4j:slf4j-api'
|
|
implementation 'joda-time:joda-time'
|
|
implementation "com.fasterxml.jackson.core:jackson-databind"
|
|
implementation "com.fasterxml.jackson.dataformat:jackson-dataformat-yaml"
|
|
|
|
implementation "com.google.guava:guava"
|
|
implementation "org.freemarker:freemarker:2.3.23"
|
|
implementation "com.fasterxml.jackson.core:jackson-core"
|
|
implementation "com.clearspring.analytics:stream:2.9.8"
|
|
implementation "net.sf.opencsv:opencsv:2.3"
|
|
implementation "com.tdunning:t-digest:3.2"
|
|
implementation "it.unimi.dsi:fastutil:8.1.1"
|
|
testImplementation 'com.tngtech.archunit:archunit-junit5-engine:0.17.0'
|
|
implementation "com.fasterxml.jackson.datatype:jackson-datatype-joda"
|
|
testImplementation "com.fasterxml.jackson.dataformat:jackson-dataformat-xml"
|
|
testImplementation 'org.hamcrest:hamcrest-api:1.0'
|
|
testImplementation 'org.hamcrest:hamcrest-core:1.3'
|
|
|
|
|
|
|
|
implementation 'org.bytedeco:javacpp'
|
|
|
|
}
|
|
|