Add seperate build definitions for CI and PR builds (#112)

This commit is contained in:
Kamil Pajdzik 2019-05-13 09:56:34 -07:00 коммит произвёл GitHub
Родитель fb93d01a2d
Коммит 30e07c2ff8
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
2 изменённых файлов: 72 добавлений и 0 удалений

Просмотреть файл

Просмотреть файл

@ -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