This repository has been archived by the owner on Jan 8, 2019. It is now read-only.
/
build.gradle
79 lines (66 loc) · 2.04 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
#!groovy
/*
Copyright (c) 2009 David Savage.
This file is part of "cong".
cong is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
cong is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with cong. If not, see <http://www.gnu.org/licenses/>.
needs: java -jar selenium-server.jar -interactive
and: a running cong (grails run-app)
*/
repositories {
mavenCentral()
mavenRepo urls: 'http://www.easyb.org/repoa/'
mavenRepo urls: 'http://nexus.openqa.org/content/repositories/releases'
}
usePlugin 'groovy'
configurations {
easybtaskdef {
transitive = true
}
easybrunner.extendsFrom easybtaskdef
}
dependencies {
easybtaskdef(
'org.easyb:easyb:0.9.6',
'commons-cli:commons-cli:1.2',
'org.codehaus.groovy:groovy-all:1.6.4'
)
easybrunner (
'org.seleniumhq.selenium.client-drivers:selenium-java-client-driver:1.0.1'
)
}
defaultTasks 'prep', 'run'
def behaviorTestDir = 'test/behavior'
def easybTxtreport = 'test/reports/easybStories.txt'
task prep << {
def reportDir = new File('test/reports')
reportDir.mkdir()
def report = new File("${easybTxtreport}")
if (report.exists()) {
report.delete()
}
}
task run << {
ant.taskdef(
name: 'easyb',
classname: 'org.easyb.ant.BehaviorRunnerTask',
classpath: configurations.easybtaskdef.asPath
)
ant.easyb(failureProperty: 'easyb.failed') {
classpath {
pathelement path: configurations.easybrunner.asPath
}
behaviors(dir: '.') {
include name: "${behaviorTestDir}/**/*Story.groovy"
}
report location: "${easybTxtreport}", format: 'txtstory'
}
}