pipeline { agent any stages { stage("Props.Shop") { stages { stage("Restore") { steps { dotnetRestore project: "Props.Shop/Props.Shop.sln", sdk: 'System' dotnetRestore project: "Props.Shop/Props.Shop.Tests.sln", sdk: 'System' } } stage("Test") { steps { dotnetTest logger: 'xunit', noRestore: true, project: 'Props.Shop/Props.Shop.Tests.sln', unstableIfErrors: true, unstableIfWarnings: true xunit([xUnitDotNet(excludesPattern: '', pattern: 'Props.Shop/*.Tests/TestReports/*.xml', stopProcessingIfError: true)]) } } stage("Publish") { steps { dotnetPublish configuration: 'Release', noRestore: true, project: 'Props.Shop/Props.Shop.sln', selfContained: false, unstableIfWarnings: true archiveArtifacts artifacts: 'Props.Shop/**/bin/Release/**/publish/Props.Shop.*', excludes: 'Props.Shop/*.Tests/**/*, **/Props.Shop.Framework.*', fingerprint: true, followSymlinks: false, onlyIfSuccessful: true archiveArtifacts artifacts: 'Props.Shop/Framework/bin/Release/**/publish/Props.Shop.Framework.*', fingerprint: true, followSymlinks: false, onlyIfSuccessful: true sh "python3 scripts/load_shop_modules.py" } } } } stage("Props") { stages { stage("Restore") { steps { dotnetRestore project: "Props" dotnetRestore project: "Props.Tests" } } stage("Test") { steps { dotnetTest logger: 'xunit', noRestore: true, project: 'Props.Tests', unstableIfErrors: true, unstableIfWarnings: true xunit([xUnitDotNet(excludesPattern: '', pattern: 'Props.Tests/TestReports/*.xml', stopProcessingIfError: true)]) } } stage("Publish") { steps { dotnetPublish configuration: 'Release', project: 'Props', runtime: 'linux-x64', selfContained: true dotnetPublish configuration: 'Release', project: 'Props', runtime: 'win-x64', selfContained: true archiveArtifacts artifacts: 'Props/bin/Release/**/publish/Props*', excludes: '**/Props.Shop.Framework.*', fingerprint: true, followSymlinks: false, onlyIfSuccessful: true } } } } stage("cleanup") { steps { cleanWs(patterns: [[pattern: '**/bin/Release', type: 'INCLUDE']]) } } } }