-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile.Selenium
29 lines (26 loc) · 1.21 KB
/
Jenkinsfile.Selenium
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
stage("selenium test") {
steps {
echo 'Invoking automated test cases in docker '
echo 'stop the docker container'
sh "chmod +x robot.sh"
sh "./robot.sh stop-test dev"
echo 'build the docker selenium container'
sh "./robot.sh rebuild-test dev"
echo 'start docker container'
sh "./robot.sh start-test dev"
sh "set +e"
sh "rm -rf report"
sh "set -e"
sh "mkdir report"
echo 'copy test cases report from docker container'
sh "docker cp selenium-testsuite:home/robotframework/src/test/selenium-robot/output.xml report"
sh "docker cp selenium-testsuite:home/robotframework/src/test/selenium-robot/log.html report"
sh "docker cp selenium-testsuite:home/robotframework/src/test/selenium-robot/report.html report"
}
}
stage('Archive Automation Test Results') {
steps {
echo 'Archive Automation Test Results'
step([$class: 'RobotPublisher', disableArchiveOutput: false, logFileName: 'log.html', otherFiles: '', outputFileName: 'output.xml', outputPath: 'report/', passThreshold: 100, reportFileName: 'report.html', unstableThreshold: 0]);
}
}