-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
155 lines (130 loc) · 5.23 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
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
plugins {
id 'org.springframework.boot' version '3.3.0'
id 'io.spring.dependency-management' version '1.1.5'
id 'java'
id 'com.adarshr.test-logger' version '4.0.0'
id "io.sentry.jvm.gradle" version "4.7.1"
}
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
configurations.configureEach {
resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
}
def props = new Properties()
if (file(".env").exists()) {
file(".env").withInputStream { props.load(it) }
}
repositories {
maven {
url 'https://oss.sonatype.org/content/repositories/snapshots'
}
mavenCentral()
}
def profile = props.getProperty('SPRING_PROFILES_ACTIVE')
def formFlowLibraryVersion = '1.3.4'
def useLocalLibrary = System.getenv('USE_LOCAL_LIBRARY')
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'com.jcraft:jsch:0.1.55'
implementation 'org.springframework.shell:spring-shell-starter:3.3.0'
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation("com.mixpanel:mixpanel-java:1.5.3")
implementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.5.6'
implementation group: 'ch.qos.logback.contrib', name: 'logback-json-classic', version: '0.1.5'
implementation group: 'ch.qos.logback.contrib', name: 'logback-jackson', version: '0.1.5'
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.17.1'
implementation 'com.opencsv:opencsv:5.9'
implementation "org.codeforamerica.platform:form-flow:${formFlowLibraryVersion}"
println "📚Using form flow library ${formFlowLibraryVersion}"
implementation 'com.amazonaws:aws-encryption-sdk-java:3.0.1'
implementation 'org.bouncycastle:bcpg-jdk15on:1.70'
implementation 'org.bouncycastle:bcpkix-jdk15on:1.70'
implementation 'org.springframework.shell:spring-shell-starter:3.3.0'
implementation 'commons-net:commons-net:3.11.1'
implementation 'com.google.api-client:google-api-client:2.6.0'
implementation 'com.google.oauth-client:google-oauth-client-jetty:1.36.0'
implementation 'com.google.apis:google-api-services-drive:v3-rev20240521-2.0.0'
implementation 'io.sentry:sentry-spring-boot-starter-jakarta:7.10.0'
implementation 'io.sentry:sentry-logback:7.10.0'
compileOnly 'org.projectlombok:lombok'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.projectlombok:lombok:1.18.32'
testImplementation 'junit:junit:4.13.2'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.springframework.security:spring-security-test'
testImplementation 'org.apache.httpcomponents.client5:httpclient5:5.3.1'
testImplementation 'org.seleniumhq.selenium:selenium-java:4.21.0'
testImplementation 'io.percy:percy-java-selenium:2.0.5'
testImplementation 'org.awaitility:awaitility'
testImplementation 'io.github.bonigarcia:webdrivermanager:5.8.0'
testImplementation 'com.deque.html.axe-core:selenium:4.9.1'
testAnnotationProcessor 'org.projectlombok:lombok'
testCompileOnly 'org.projectlombok:lombok'
runtimeOnly 'org.postgresql:postgresql'
}
springBoot {
buildInfo()
}
dependencyManagement {
imports {
mavenBom "org.springframework.shell:spring-shell-dependencies:3.3.0"
}
}
test {
useJUnitPlatform {
JUnitPlatformOptions options ->
options.excludeTags("a11y")
}
}
def unitTest = tasks.register("unitTest", Test) {
Test task ->
task.useJUnitPlatform {
JUnitPlatformOptions options ->
options.excludeTags("a11y")
}
}
def axeAccessibilityTest = tasks.register("accessibilityTest", Test) {
Test task ->
task.useJUnitPlatform {
JUnitPlatformOptions options ->
options.includeTags 'a11y'
}
}
tasks.withType(Test).configureEach {
Test task ->
task.testLogging {
exceptionFormat = "full"
events = ["failed", "skipped"]
showStackTraces = true
showCauses = true
showExceptions = true
// uncomment the following line to print stdout and stderr for every test
// showStandardStreams = true
}
print "🌟Running test configuration 🌟"
// override a few things.
environment("DEFAULT_LOCALE", "en")
// setting "SENTRY_DSN" to "" essentially turns off reporting to Sentry
environment("SENTRY_DSN", "")
environment("SENTRY_AUTH_TOKEN", "")
environment("MIXPANEL_API_KEY", "this-is-a-dummy-key-for-md-tests")
}
jar {
enabled false
}
if (profile == 'staging' || profile == 'prod') {
sentry {
// Generates a JVM (Java, Kotlin, etc.) source bundle and uploads your source code to Sentry.
// This enables source context, allowing you to see your source
// code as part of your stack traces in Sentry.
includeSourceContext = true
org = "codeforamerica"
projectName = "md-pilot"
authToken = System.getenv("SENTRY_AUTH_TOKEN")
}
}