adding jenkinsfile

This commit is contained in:
Andy Pack 2023-10-08 18:25:15 +01:00
parent 8f3ce5e959
commit 97538659e3
Signed by: sarsoo
GPG Key ID: A55BA3536A5E0ED7
2 changed files with 51 additions and 2 deletions

49
.jenkins/jenkinsfile Normal file
View File

@ -0,0 +1,49 @@
pipeline {
agent any
stages {
stage('Build') {
// agent {
// docker {
// image 'mcr.microsoft.com/dotnet/sdk:6.0'
// }
// }
steps {
dotnetRestore project: "Mixonomer.NET.sln"
dotnetBuild project: 'Mixonomer.NET.sln'
}
}
stage('Test') {
// agent {
// docker {
// image 'mcr.microsoft.com/dotnet/sdk:6.0'
// reuseNode true
// }
// }
steps {
dotnetTest project: "Mixonomer.NET.sln"
}
}
// stage('Deploy') {
// when { branch 'master' }
// steps {
// script {
// docker.withRegistry('https://registry.sarsoo.xyz', 'git-registry-creds') {
// docker.build("sarsoo/selector-cli:latest",
// "-f Dockerfile.CLI .").push()
// docker.build("sarsoo/selector-web:latest",
// "-f Dockerfile.Web .").push()
// }
// }
// }
// }
}
post {
always {
cleanWs()
}
}
}

View File

@ -9,9 +9,9 @@ namespace Mixonomer.Tests
[Fact]
public async void Test1()
{
var repo = new UserRepo();
// var repo = new UserRepo();
var user = await repo.GetUser("andy");
// var user = await repo.GetUser("andy");
}
}
}