forked from Wikia/selenium-tests
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
126 lines (107 loc) · 4.22 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
buildscript {
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath 'org.ajoberstar:gradle-git:1.0.0'
classpath 'com.palominolabs.gradle.task:gradle-git-clone-task:0.0.2'
classpath 'org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.5'
}
}
plugins {
id 'nebula.lint' version '9.3.4'
}
repositories {
mavenCentral()
jcenter()
}
apply plugin: 'nebula.lint'
apply plugin: 'java'
apply plugin: 'org.sonarqube'
sonarqube {
properties {
property "sonar.host.url", "http://sonarqube.sjc-dev.k8s.wikia.net"
property "sonar.sourceEncoding", "UTF-8"
property "sonar.exclusions", "**/main/resources/**, **/test/resources/**"
property "sonar.projectKey", "com.wikia.selenium-tests"
}
}
group = 'com.wikia.qa'
version = '1.0.0'
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
compileJava.options.encoding = 'UTF-8'
compileTestJava.options.encoding = 'UTF-8'
gradleLint.rules = ['all-dependency'] // add as many rules here as you'd like
ext {
testSuite = 'src/test/java/com/wikia/webdriver/testsuites/testSuite.xml'
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
tasks.withType(Test) {
systemProperties = System.getProperties()
}
import org.gradle.api.tasks.testing.logging.TestExceptionFormat
// docs: https://gradle.org/docs/current/dsl/org.gradle.api.tasks.testing.Test.html
test {
ignoreFailures = true;
def groups = ''
if(!project.hasProperty('failedMatrix')) {
groups = project.hasProperty('groups') ? groups : System.getProperty('groups', '')
}else{
groups = "NOT EXISITNG"
}
useTestNG {
suiteXmlFiles = testSuite.split(',').
collect({ path -> new File(path) })
includeGroups = groups.split(',')
useDefaultListeners = true
scanForTestClasses = false
testLogging.showStandardStreams = true
testLogging.showStackTraces = true
testLogging.exceptionFormat = TestExceptionFormat.FULL
configFailurePolicy = 'continue'
}
outputs.upToDateWhen { false }
}
dependencies {
def webdriverVersion = '3.141.59'
testCompile "org.apache.velocity:velocity:1.7"
testCompile "org.seleniumhq.selenium:selenium-chrome-driver:${webdriverVersion}"
testCompile "org.seleniumhq.selenium:selenium-api:${webdriverVersion}"
testCompile "org.seleniumhq.selenium:selenium-firefox-driver:${webdriverVersion}"
testCompile "org.seleniumhq.selenium:selenium-support:${webdriverVersion}"
testCompile 'org.apache.httpcomponents:httpcore:4.4.9'
testCompile 'org.apache.commons:commons-lang3:3.8.1'
testCompile 'com.github.detro.ghostdriver:phantomjsdriver:1.1.0'
testCompile 'org.testng:testng:6.9.6'
testCompile 'com.google.guava:guava:25.0-jre'
testCompile 'org.yaml:snakeyaml:1.15'
testCompile 'org.apache.httpcomponents:httpclient:4.5.5'
testCompile 'javax.mail:mail:1.4.4'
testCompile 'org.apache.commons:commons-configuration2:2.3'
testCompile 'org.json:json:20080701'
testCompile 'io.appium:java-client:3.1.0'
testCompile 'joda-time:joda-time:2.7'
testCompile 'com.jayway.jsonpath:json-path:2.2.0'
testCompile 'net.lightbody.bmp:browsermob-core:2.1.5'
testCompile 'net.sourceforge.htmlunit:htmlunit:2.18'
testCompile 'org.projectlombok:lombok:1.18.2'
testCompile 'org.assertj:assertj-core:3.8.0'
testCompile 'ru.yandex.qatools.ashot:ashot:1.5.2'
testCompile 'com.squareup.okhttp3:okhttp:3.10.0'
testCompile 'com.google.code.findbugs:jsr305:1.3.9'
testCompile 'commons-collections:commons-collections:3.2.2'
testCompile 'net.lightbody.bmp:mitm:2.1.5'
testCompile 'org.seleniumhq.selenium:selenium-htmlunit-driver:2.47.2'
testCompile 'org.seleniumhq.selenium:selenium-remote-driver:3.141.59'
testCompile 'com.google.code.findbugs:jsr305:1.3.9'
testCompile 'net.lightbody.bmp:mitm:2.1.5'
testCompile 'org.seleniumhq.selenium:selenium-remote-driver:3.13.0'
testRuntimeOnly 'commons-beanutils:commons-beanutils:1.9.3'
testCompile 'commons-io:commons-io:2.4'
testCompile 'commons-lang:commons-lang:2.4'
testCompile group: 'org.slf4j', name: 'slf4j-log4j12', version: '1.7.25'
}