2019-04-07 09:07:52 +03:00
|
|
|
trigger:
|
|
|
|
- master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
- job: Build
|
|
|
|
displayName: Build
|
|
|
|
pool:
|
|
|
|
vmImage: 'Ubuntu-16.04'
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- script: npm run build
|
|
|
|
displayName: Build
|
2019-04-07 22:49:10 +03:00
|
|
|
- script: |
|
|
|
|
npm pack
|
|
|
|
mv html2canvas-*.tgz html2canvas.tgz
|
|
|
|
tar --list --verbose --file=html2canvas.tgz
|
|
|
|
displayName: Pack
|
|
|
|
name: pack
|
|
|
|
- task: PublishBuildArtifacts@1
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: html2canvas.tgz
|
|
|
|
artifactName: npm
|
2019-04-07 09:07:52 +03:00
|
|
|
- task: PublishBuildArtifacts@1
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'dist'
|
|
|
|
artifactName: dist
|
|
|
|
- task: PublishBuildArtifacts@1
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'build'
|
|
|
|
artifactName: build
|
|
|
|
- job: Test
|
|
|
|
displayName: Tests
|
|
|
|
pool:
|
|
|
|
vmImage: 'Ubuntu-16.04'
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- script: npm run build
|
|
|
|
displayName: Build
|
|
|
|
- script: npm run lint
|
|
|
|
displayName: Lint
|
|
|
|
- script: npm run flow
|
|
|
|
displayName: Flow
|
|
|
|
- script: npm run test:node
|
|
|
|
displayName: Unit tests
|
|
|
|
- job: Build_docs
|
|
|
|
displayName: Build docs
|
|
|
|
pool:
|
|
|
|
vmImage: 'Ubuntu-16.04'
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- script: npm run build && cd www && npm install && npm run build && cd ..
|
|
|
|
displayName: Build docs
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload docs website artifact
|
2019-04-07 09:07:52 +03:00
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'www/public'
|
|
|
|
artifactName: docs
|
|
|
|
- job: Browser_Tests_Linux_Firefox_Stable
|
|
|
|
displayName: Linux Firefox Stable
|
|
|
|
pool:
|
|
|
|
vmImage: 'Ubuntu-16.04'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: Firefox_Stable
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: Xvfb :99 &
|
|
|
|
displayName: 'Start Xvfb'
|
|
|
|
- script: DISPLAY=:99 npm run karma
|
|
|
|
displayName: 'Run Firefox tests - Firefox Stable'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|
|
|
|
- job: Browser_Tests_Linux_Chrome_Stable
|
|
|
|
displayName: Linux Chrome Stable
|
|
|
|
pool:
|
|
|
|
vmImage: 'Ubuntu-16.04'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: Chrome_Stable
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: Xvfb :99 &
|
|
|
|
displayName: 'Start Xvfb'
|
|
|
|
- script: DISPLAY=:99 npm run karma
|
|
|
|
displayName: 'Run Chrome tests - Chrome Stable'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|
|
|
|
- job: Browser_Tests_OSX_Safari_Stable
|
|
|
|
displayName: OSX Safari Stable
|
|
|
|
pool:
|
|
|
|
vmImage: 'macOS-10.13'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: Safari_Stable
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: npm run karma
|
|
|
|
displayName: 'Run Safari tests - Safari Stable'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|
|
|
|
- job: Browser_Tests_Windows_IE9
|
|
|
|
displayName: Windows Internet Explorer 9 (Emulated)
|
|
|
|
pool:
|
|
|
|
vmImage: 'vs2017-win2016'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: IE_9
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: npm run karma
|
|
|
|
displayName: 'Run Internet Explorer tests - IE 9'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|
|
|
|
- job: Browser_Tests_Windows_IE10
|
|
|
|
displayName: Windows Internet Explorer 10 (Emulated)
|
|
|
|
pool:
|
|
|
|
vmImage: 'vs2017-win2016'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: IE_10
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: npm run karma
|
|
|
|
displayName: 'Run Internet Explorer tests - IE 10'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|
|
|
|
- job: Browser_Tests_Windows_IE11
|
|
|
|
displayName: Windows Internet Explorer 11
|
|
|
|
pool:
|
|
|
|
vmImage: 'vs2017-win2016'
|
|
|
|
variables:
|
|
|
|
TARGET_BROWSER: IE_11
|
|
|
|
dependsOn: Build
|
|
|
|
condition: succeeded()
|
|
|
|
steps:
|
|
|
|
- task: NodeTool@0
|
|
|
|
inputs:
|
|
|
|
versionSpec: '10.x'
|
|
|
|
displayName: 'Install Node.js'
|
|
|
|
- task: Npm@0
|
|
|
|
inputs:
|
|
|
|
command: install
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download library'
|
|
|
|
inputs:
|
|
|
|
artifactName: dist
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- task: DownloadBuildArtifacts@0
|
|
|
|
displayName: 'Download testrunner'
|
|
|
|
inputs:
|
|
|
|
artifactName: build
|
|
|
|
downloadPath: $(System.DefaultWorkingDirectory)
|
|
|
|
- script: npm run karma
|
|
|
|
displayName: 'Run Internet Explorer tests - IE 11'
|
|
|
|
- task: PublishTestResults@2
|
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
testRunner: JUnit
|
|
|
|
testResultsFiles: 'tmp/junit/*.xml'
|
|
|
|
- task: PublishBuildArtifacts@1
|
2019-04-07 22:49:10 +03:00
|
|
|
displayName: Upload Screenshots
|
2019-04-07 09:07:52 +03:00
|
|
|
condition: succeededOrFailed()
|
|
|
|
inputs:
|
|
|
|
PathtoPublish: 'tmp/reftests'
|
|
|
|
artifactName: ReftestResults
|