From 1b9d1428e6a2b16da21529c2f20e3d44238a2880 Mon Sep 17 00:00:00 2001 From: Paul Johnson Date: Fri, 11 Dec 2020 14:35:12 +0000 Subject: [PATCH] Update ci pipeline build definition --- build/azure-pipelines.yml | 38 +++++++++++++++++++++++++++++++++++--- 1 file changed, 35 insertions(+), 3 deletions(-) diff --git a/build/azure-pipelines.yml b/build/azure-pipelines.yml index 8a99f941b0..d301b9c461 100644 --- a/build/azure-pipelines.yml +++ b/build/azure-pipelines.yml @@ -8,6 +8,19 @@ # Variables & their default values variables: buildConfiguration: 'Release' + SA_PASSWORD: UmbracoIntegration123! + +resources: + containers: + - container: mssql + image: mcr.microsoft.com/mssql/server:2017-latest + env: + ACCEPT_EULA: Y + SA_PASSWORD: $(SA_PASSWORD) + MSSQL_PID: Developer + ports: + - 1433:1433 + options: --name mssql stages: - stage: Linux @@ -31,6 +44,28 @@ stages: command: test projects: '**/*.Tests.UnitTests.csproj' + - job: Integration_Tests + services: + mssql: mssql + timeoutInMinutes: 120 + displayName: 'Integration Tests' + pool: + vmImage: 'ubuntu-latest' + steps: + + - task: UseDotNet@2 + displayName: 'Use .Net Core sdk 3.1.x' + inputs: + version: 3.1.x + + - task: DotNetCoreCLI@2 + displayName: 'dotnet test' + inputs: + command: test + projects: '**/Umbraco.Tests.Integration.csproj' + env: + UmbracoIntegrationTestConnectionString: 'Server=localhost,1433;User Id=sa;Password=$(SA_PASSWORD);' + - stage: macOS_X dependsOn: [] # this removes the implicit dependency on previous stage and causes this to run in parallel jobs: @@ -52,7 +87,6 @@ stages: command: test projects: '**/*.Tests.UnitTests.csproj' - - stage: Windows dependsOn: [] # this removes the implicit dependency on previous stage and causes this to run in parallel jobs: @@ -74,7 +108,6 @@ stages: command: test projects: '**\*.Tests.UnitTests.csproj' - - job: Integration_Tests timeoutInMinutes: 120 displayName: 'Integration Tests' @@ -102,7 +135,6 @@ stages: projects: '**\Umbraco.Tests.Integration.csproj' arguments: '--no-build' - - job: Build_Artifacts displayName: 'Build Artifacts' pool: