This repository has been archived by the owner on Sep 14, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.gradle
111 lines (97 loc) · 3.41 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
plugins {
id 'application'
id 'io.spring.dependency-management' version '1.0.4.RELEASE'
id 'org.springframework.boot' version '2.0.1.RELEASE'
id 'org.owasp.dependencycheck' version '3.1.2'
id 'com.github.ben-manes.versions' version '0.17.0'
id 'org.sonarqube' version '2.6.2'
id 'jacoco'
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'application'
apply plugin: 'io.spring.dependency-management'
apply plugin: 'org.springframework.boot'
apply plugin: 'org.owasp.dependencycheck'
apply plugin: 'com.github.ben-manes.versions'
group = 'uk.gov.hmcts.reform.rpa'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = 1.8
mainClassName = 'uk.gov.hmcts.reform.rpa.incourtpres.IncourtPresApplication'
configurations {
aatCompile.extendsFrom(testCompile)
aatRuntime.extendsFrom(testRuntime)
}
dependencyCheck {
// Specifies if the build should be failed if a CVSS score above a specified level is identified.
// range of 0-10 fails the build, anything greater and it doesn't fail the build
failBuildOnCVSS = System.getProperty('dependencyCheck.failBuild') == 'false' ? 11 : 0
suppressionFile = 'dependency-check-suppressions.xml'
analyzers {
// Disable scanning of .NET related binaries
assemblyEnabled = false
}
}
repositories {
maven {
url "https://dl.bintray.com/hmcts/hmcts-maven"
}
maven { url "https://repo.spring.io/snapshot" }
maven { url "https://repo.spring.io/milestone" }
jcenter()
mavenLocal()
}
def versions = [
postgresql : '42.2.2',
springBoot : '2.0.1.RELEASE',
hmctsJavaLogging : '3.0.0'
]
dependencies {
compile('org.springframework.boot:spring-boot-starter-actuator')
// compile('org.springframework.boot:spring-boot-starter-data-jpa')
compile('org.springframework.boot:spring-boot-starter-web')
compile('org.springframework.boot:spring-boot-starter-websocket')
compile("org.postgresql:postgresql:${versions.postgresql}")
compile("uk.gov.hmcts.reform:java-logging-spring:${versions.hmctsJavaLogging}")
compile("uk.gov.hmcts.reform:java-logging-httpcomponents:${versions.hmctsJavaLogging}")
compile("uk.gov.hmcts.reform:java-logging-appinsights:${versions.hmctsJavaLogging}")
runtime('org.springframework.boot:spring-boot-devtools')
testCompile('org.springframework.boot:spring-boot-starter-test')
testCompile('com.h2database:h2:1.4.197')
}
sourceSets {
aat {
java {
compileClasspath += main.output
runtimeClasspath += main.output
srcDir('src/aat/java')
}
resources {
srcDir('src/aat/resources')
}
}
}
task functional(type: Test) {
group = 'Delivery pipeline'
description = 'Executes functional tests against an AAT In Court Presentation instance'
setTestClassesDirs(sourceSets.aat.output.classesDirs)
setClasspath(sourceSets.aat.runtimeClasspath)
include "uk/gov/hmcts/reform/rpa/incourtpres/functional/**"
environment("APPINSIGHTS_INSTRUMENTATIONKEY", "test-key")
}
task smoke(type: Test) {
group = 'Delivery pipeline'
description = 'Executes non-destructive smoke tests against a running In Court Presentation instance'
setTestClassesDirs(sourceSets.aat.output.classesDirs)
setClasspath(sourceSets.aat.runtimeClasspath)
include "uk/gov/hmcts/reform/rpa/incourtpres/smoke/**"
environment("APPINSIGHTS_INSTRUMENTATIONKEY", "test-key")
}
bootJar {
baseName 'rpa-icp'
archiveName = "$baseName"+".jar"
destinationDir = file("$rootDir/build/libs")
manifest {
attributes 'Implementation-Title': project.name, 'Implementation-Version': project.version
}
}