-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
92 lines (80 loc) · 2.35 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
plugins {
id "java-library"
id "io.qameta.allure" version "2.9.6"
}
repositories {
mavenCentral()
}
def junitVersion = "5.8.2",
selenideVersion = "6.4.0",
allureVersion = "2.17.3",
restAssuredVersion = "5.0.1",
slf4jVersion = "1.7.36",
ownerVersion = "1.0.12",
assertjVersion = "3.22.0",
appiumVersion = "8.0.0",
commonsioVersion = "2.11.0"
dependencies {
testImplementation(
"org.junit.jupiter:junit-jupiter:$junitVersion",
"com.codeborne:selenide:$selenideVersion",
"io.qameta.allure:allure-selenide:$allureVersion",
"io.qameta.allure:allure-rest-assured:$allureVersion",
"io.rest-assured:rest-assured:$restAssuredVersion",
"org.slf4j:slf4j-simple:$slf4jVersion",
"org.aeonbits.owner:owner:$ownerVersion",
"org.assertj:assertj-core:$assertjVersion",
"io.appium:java-client:$appiumVersion",
"commons-io:commons-io:$commonsioVersion"
)
}
allure {
adapter {
aspectjWeaver.set(true)
frameworks {
junit5 {
adapterVersion.set(allureVersion)
}
}
}
report {
version.set(allureVersion)
}
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
tasks.withType(Test) {
systemProperties(System.getProperties())
useJUnitPlatform()
if (System.getProperty("threads") != null) {
systemProperties += [
'junit.jupiter.execution.parallel.enabled' : true,
'junit.jupiter.execution.parallel.mode.default' : 'concurrent',
'junit.jupiter.execution.parallel.mode.classes.default' : 'concurrent',
'junit.jupiter.execution.parallel.config.strategy' : 'fixed',
'junit.jupiter.execution.parallel.config.fixed.parallelism': System.getProperty("threads").toInteger()
]
}
testLogging {
lifecycle {
events "started", "skipped", "failed", "standard_error", "standard_out"
exceptionFormat "short"
}
}
}
task web_test(type: Test) {
useJUnitPlatform {
includeTags "web"
}
}
task api_test(type: Test) {
useJUnitPlatform {
includeTags "api"
}
}
task mobile_test(type: Test) {
useJUnitPlatform {
includeTags "mobile"
}
}