From 30e07c2ff888819e7e887dc7d6996d10415a8de0 Mon Sep 17 00:00:00 2001 From: Kamil Pajdzik <41709775+kpajdzik@users.noreply.github.com> Date: Mon, 13 May 2019 09:56:34 -0700 Subject: [PATCH] Add seperate build definitions for CI and PR builds (#112) --- .../azure-pipelines-ci.yml | 0 .devops/azure-pipelines-pr.yml | 72 +++++++++++++++++++ 2 files changed, 72 insertions(+) rename azure-pipelines.yml => .devops/azure-pipelines-ci.yml (100%) create mode 100644 .devops/azure-pipelines-pr.yml diff --git a/azure-pipelines.yml b/.devops/azure-pipelines-ci.yml similarity index 100% rename from azure-pipelines.yml rename to .devops/azure-pipelines-ci.yml diff --git a/.devops/azure-pipelines-pr.yml b/.devops/azure-pipelines-pr.yml new file mode 100644 index 0000000..6d0366c --- /dev/null +++ b/.devops/azure-pipelines-pr.yml @@ -0,0 +1,72 @@ +trigger: +- master + +jobs: +- job: Check_Everything + pool: + vmImage: 'Ubuntu 16.04' + steps: + - task: Npm@1 + displayName: 'npm install' + inputs: + command: custom + verbose: false + customCommand: install + - task: Npm@1 + displayName: 'npm run check:everything -- --azure-devops' + inputs: + command: custom + verbose: false + customCommand: run check:everything -- --azure-devops +- job: Test + pool: + vmImage: 'Ubuntu 16.04' + strategy: + matrix: + Node6: + node.version: 6.x + Node8: + node.version: 8.x + Node10: + node.version: 10.x + Node11: + node.version: 11.x + steps: + - task: NodeTool@0 + displayName: 'Install Node' + inputs: + versionSpec: $(node.version) + - script: npm install + - task: Npm@1 + displayName: 'npm test' + inputs: + command: custom + verbose: false + customCommand: test + - task: PublishTestResults@2 + inputs: + testResultsFiles: '$(System.DefaultWorkingDirectory)/test-results.xml' + testRunTitle: 'Test results for JavaScript' + - task: PublishCodeCoverageResults@1 + inputs: + codeCoverageTool: Cobertura + summaryFileLocation: '$(System.DefaultWorkingDirectory)/coverage/cobertura-coverage.xml' + reportDirectory: '$(System.DefaultWorkingDirectory)/coverage/' +- job: Build + pool: + vmImage: 'Ubuntu 16.04' + steps: + - task: Npm@1 + displayName: 'npm pack' + inputs: + command: custom + verbose: false + customCommand: pack + - task: CopyFiles@2 + displayName: 'Copy Files to: drop' + inputs: + Contents: '*.tgz' + TargetFolder: drop + - task: PublishBuildArtifacts@1 + inputs: + pathtoPublish: $(Build.SourcesDirectory)/drop \ No newline at end of file