forked from browserstack/testng-browserstack
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
35 lines (29 loc) · 954 Bytes
/
build.gradle
File metadata and controls
35 lines (29 loc) · 954 Bytes
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
plugins {
id 'java'
}
repositories { mavenCentral() }
dependencies {
testImplementation 'org.testng:testng:7.7.1'
implementation 'org.seleniumhq.selenium:selenium-java:4.1.4'
implementation 'com.googlecode.json-simple:json-simple:1.1.1'
compileOnly 'com.browserstack:browserstack-java-sdk:latest.release'
}
group = 'com.browserstack'
version = '1.0-SNAPSHOT'
description = 'now-testng-browserstack'
sourceCompatibility = '11'
def browserstackSDKArtifact = configurations.compileClasspath.resolvedConfiguration.resolvedArtifacts.find { it.name == 'browserstack-java-sdk' }
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
tasks.withType(Test) {
systemProperties = System.properties
}
task sampleTest(type: Test) {
useTestNG() {
dependsOn cleanTest
useDefaultListeners = true
suites "config/sample-test.testng.xml"
jvmArgs "-javaagent:${browserstackSDKArtifact.file}"
}
}