We are using Katalon, GitHub and Jenkins in MultiBranch Pipeline Jenkins Job.
Part of all of that is JenkinsFile.
I need to make changes to it.
However I am not sure can I and should I use Katalon Studio for that?
Dejan Dzodan said:
We are using Katalon, GitHub and Jenkins in MultiBranch Pipeline Jenkins Job.
Part of all of that is JenkinsFile.
I need to make changes to it.
However I am not sure can I and should I use Katalon Studio for that?
You can and I guess you should
The way to fetch your test code from github would be something like this
stage ('Fetch Test Code') {
steps {
sh "git clone https://github.com/katalon-studio/docker-images-samples.git"
print "Place holder for Fetching Test Code from github"
}
}
The way to pull docker image, execute tests, and upload results back would be something like this
(run_chrome.sh is the same or similar to the one provided with Katalon Docker sample on Github)
stage('Run tests') {
steps {
print " automatic test"
sh """
"sudo docker pull katalonstudio/katalon;
sudo chmod +x ./ABCTest/run_chrome.sh;
sudo ./ABCTest/run_chrome.sh " ;
""";
}
post {
always {
sh """
mkdir testresult;
scp -i ${env.SSH\_KEY\_ID}.pem -o ConnectTimeout=60 -o StrictHostKeyChecking=no -p host@${demo\_instance\_IP}:~/reports/chrome/JUnit_Report.xml testresult;
"""
junit 'testresult/*.xml'
}
}
}
1 Like