diff --git a/.azure/azure-ci-build-pipeline.yaml b/.azure/azure-ci-build-pipeline.yaml index 6951e350..0b02626c 100644 --- a/.azure/azure-ci-build-pipeline.yaml +++ b/.azure/azure-ci-build-pipeline.yaml @@ -86,5 +86,14 @@ stages: displayName: 'Perform PrimAITE Setup' - script: | - pytest --cov=src --cov-report=html:coverage_report --cov-fail-under=80 + pytest --cov=src --cov-report=html:coverage_report --cov-report=xml --cov-fail-under=80 displayName: 'Run tests and code coverage' + + - task: PublishCodeCoverageResults@1 + displayName: 'Publish coverage report' + condition: succeededOrFailed() + inputs: + codeCoverageTool: Cobertura + summaryFileLocation: 'coverage.xml' + reportDirectory: 'coverage_report' + failIfCoverageEmpty: true