This repository has been archived by the owner on Nov 18, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathbuild.gradle
70 lines (54 loc) · 1.95 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
buildscript {
repositories {
maven { url 'https://mirrors.huaweicloud.com/repository/maven/' }
}
}
plugins {
id 'java'
id 'org.springframework.boot' version '2.1.3.RELEASE'
id 'org.flywaydb.flyway' version '5.2.4'
}
apply plugin: 'io.spring.dependency-management'
group = 'name.huhao'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = 11
targetCompatibility = 11
repositories {
maven { url 'https://mirrors.huaweicloud.com/repository/maven/' }
}
configurations {
compile.exclude module: 'junit'
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.flywaydb:flyway-core'
runtimeOnly 'org.springframework.boot:spring-boot-devtools'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
implementation 'io.springfox:springfox-swagger2:2.9.2'
implementation 'io.springfox:springfox-swagger-ui:2.9.2'
testImplementation 'org.flywaydb.flyway-test-extensions:flyway-spring-test:5.2.1'
runtimeOnly 'mysql:mysql-connector-java'
testRuntimeOnly 'com.h2database:h2'
// just use to show how to use REST Assured to improve test
// should place rest-assured before the JUnit dependency declaration in order to make sure
// that the correct version of Hamcrest is used
testImplementation 'io.rest-assured:rest-assured:3.3.0'
testImplementation 'io.rest-assured:spring-mock-mvc:3.3.0'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.4.1'
testImplementation 'org.junit.jupiter:junit-jupiter:5.4.1'
testImplementation 'org.mockito:mockito-core:2.+'
testImplementation 'org.assertj:assertj-core:3.11.1'
}
test {
useJUnitPlatform()
testLogging {
events "passed", "skipped", "failed"
}
}
flyway {
url = "jdbc:mysql://127.0.0.1:3306"
user = "root"
password = "password"
schemas = ['springboot_demo']
}