fabric-samples/asset-transfer-basic/chaincode-java/build.gradle
Francesco Vlacancich 944c23d8a1 Revert "final draft for JSON determinm task, using Genson instead of object mapper"
This reverts commit cc0f8c7bbba3ef1a0be1a9291e6c0a594b281933.

revert wrong commit cc0f8c7bbba3ef1a0be1a9291e6c0a594b281933

Signed-off-by: fraVlaca <ocsenarf@outlook.com>
2021-09-01 13:37:27 +01:00

89 lines
1.8 KiB
Groovy

/*
* SPDX-License-Identifier: Apache-2.0
*/
plugins {
id 'com.github.johnrengelman.shadow' version '5.1.0'
id 'application'
id 'checkstyle'
id 'jacoco'
}
group 'org.hyperledger.fabric.samples'
version '1.0-SNAPSHOT'
dependencies {
implementation 'org.hyperledger.fabric-chaincode-java:fabric-chaincode-shim:2.2.0'
implementation 'com.owlike:genson:1.6'
implementation 'com.google.code.gson:gson:2.8.7'
implementation 'com.fasterxml.jackson.core:jackson-databind:2.8.9'
implementation 'io.vertx:vertx-core:3.5.3'
testImplementation 'org.junit.jupiter:junit-jupiter:5.4.2'
testImplementation 'org.assertj:assertj-core:3.11.1'
testImplementation 'org.mockito:mockito-core:2.+'
}
repositories {
maven {
url "https://hyperledger.jfrog.io/hyperledger/fabric-maven"
}
jcenter()
maven {
url 'https://jitpack.io'
}
}
application {
mainClass = 'org.hyperledger.fabric.contract.ContractRouter'
}
checkstyle {
toolVersion '8.21'
configFile file("config/checkstyle/checkstyle.xml")
}
checkstyleMain {
source ='src/main/java'
}
checkstyleTest {
source ='src/test/java'
}
jacocoTestReport {
dependsOn test
}
jacocoTestCoverageVerification {
violationRules {
rule {
limit {
minimum = 0.9
}
}
}
finalizedBy jacocoTestReport
}
test {
useJUnitPlatform()
testLogging {
events "passed", "skipped", "failed"
}
}
mainClassName = 'org.hyperledger.fabric.contract.ContractRouter'
shadowJar {
baseName = 'chaincode'
version = null
classifier = null
manifest {
attributes 'Main-Class': 'org.hyperledger.fabric.contract.ContractRouter'
}
}
check.dependsOn jacocoTestCoverageVerification
installDist.dependsOn check