diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 5bce72e..1616cad 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -10,5 +10,30 @@ variables: buildConfiguration: 'Release' steps: +- task: DotNetCoreInstaller@0 + displayName: install dotnet 2.1.401 + inputs: + packageType: 'sdk' + version: '2.1.401' + - script: dotnet build LetsEncrypt.Azure.DotNetCore.sln --configuration $(buildConfiguration) displayName: 'dotnet build LetsEncrypt.Azure.DotNetCore.sln $(buildConfiguration)' + +- task: DotNetCoreCLI@2 + displayName: dotnet test + inputs: + command: test + projects: 'test/**/*.csproj' + +- task: DotNetCoreCLI@2 + displayName: dotnet pack + inputs: + command: pack + packagesToPack: 'LetsEncrypt.Azure.Core.V2/*.csproj' + packDirectory: '$(Build.ArtifactStagingDirectory)/packages' + +- task: PublishBuildArtifacts@1 + displayName: publish artifacts + condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master')) + inputs: + PathtoPublish: '$(Build.ArtifactStagingDirectory)'