-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJenkinsfile
30 lines (25 loc) · 892 Bytes
/
Jenkinsfile
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
node('master'){
stage('Clean Workspace'){
cleanWs()
}
stage('Fetch from Git'){
git url:'https://github.com/frankbj57/CoreTest.git/'
}
stage('Clean Build') {
bat '"C:\\Program Files\\dotnet\\dotnet.exe" clean coretest.sln'
}
stage('Build') {
bat '"C:\\Program Files\\dotnet\\dotnet.exe" build coretest.sln'
}
try {
stage('Run unit tests') {
// bat '"C:\\Program Files\\dotnet\\dotnet.exe" test RegisterTest\\bin\\Debug\\netcoreapp3.1\\RegisterTest.dll --logger:nunit;LogFileName=TestResults.xml'
bat '"C:\\Program Files\\dotnet\\dotnet.exe" test RegisterTest\\ --logger:nunit;LogFileName=TestResults.xml'
}
}
finally {
stage('Publish Test Results') {
nunit testResultsPattern: 'RegisterTest\\TestResults\\TestResults.xml'
}
}
}