ci(azure-pipelines): start postgres container for tests

This commit is contained in:
Sarah Vaupel 2025-02-10 15:04:47 +01:00
parent 258a240a77
commit 084b9258dd

View File

@ -123,30 +123,36 @@ stages:
ArtifactName: 'Build_${{service.name}}' ArtifactName: 'Build_${{service.name}}'
publishLocation: 'Container' publishLocation: 'Container'
# - stage: Test - stage: Test
# dependsOn: Setup dependsOn: Setup
# condition: eq(variables.skipTests, false) condition: eq(variables.skipTests, false)
# jobs: jobs:
# - ${{ each service in parameters.services }}: - task: Bash@3
# - job: Test_${{service.name}} displayName: Start database container for testing
# displayName: Compile ${{service.name}} inputs:
# dependsOn: ${{service.dependsOn}} targetType: inline
# steps: script: |
# - template: .azure-pipelines/templates/steps/make.yaml docker run -d devfra.azurecr.io/de.fraport.trusted/postgres:16.1-bookworm
# parameters: - ${{ each service in parameters.services }}:
# makeJob: lint - job: Test_${{service.name}}
# makeService: ${{service.name}} displayName: Run ${{service.name}} tests
# - template: .azure-pipelines/templates/steps/make.yaml dependsOn: ${{service.dependsOn}}
# parameters: steps:
# makeJob: test - template: .azure-pipelines/templates/steps/make.yaml
# makeService: ${{service.name}} parameters:
# - job: TestReport_${{service.name}} makeJob: lint
# displayName: Upload test reports for ${{service.name}} makeService: ${{service.name}}
# steps: - template: .azure-pipelines/templates/steps/make.yaml
# - script: echo "Work in progress" # TODO parameters:
makeJob: test
makeService: ${{service.name}}
- job: TestReport_${{service.name}}
displayName: Upload test reports for ${{service.name}}
steps:
- script: echo "Work in progress" # TODO
- stage: Release - stage: Release
dependsOn: Build # TODO include Test iff not skipped dependsOn: Test
condition: or(eq(variables.forceRelease, true), startsWith(variables['Build.SourceBranch'], 'refs/tags/')) condition: or(eq(variables.forceRelease, true), startsWith(variables['Build.SourceBranch'], 'refs/tags/'))
jobs: jobs:
- template: .azure-pipelines/templates/jobs/release.yaml - template: .azure-pipelines/templates/jobs/release.yaml