chore(ci, azure): report test results on azure pipelines (#4242)

This commit is contained in:
Kayla Ngan 2018-10-31 14:39:50 -04:00 committed by Pooya Parsa
parent 7c89a4a785
commit 3ec2579d09
4 changed files with 31 additions and 3 deletions

View File

@ -20,9 +20,15 @@ steps:
displayName: 'Install dependencies' displayName: 'Install dependencies'
- script: | - script: |
yarn test:fixtures -w=2 set JEST_JUNIT_OUTPUT=test-fixtures-junit.xml && yarn test:fixtures -w=2
displayName: 'Test: Build Fixtures' displayName: 'Test: Build Fixtures'
- script: | - script: |
yarn test:unit -w=2 set JEST_JUNIT_OUTPUT=test-unit-junit.xml && yarn test:unit -w=2
displayName: 'Test: Run unit tests' displayName: 'Test: Run unit tests'
- task: PublishTestResults@2
inputs:
testResultsFormat: 'JUnit'
testResultsFiles: 'test-*.xml'
displayName: 'Publish test results to Azure Pipelines'

View File

@ -40,5 +40,10 @@ module.exports = {
moduleFileExtensions: [ moduleFileExtensions: [
'js', 'js',
'json' 'json'
],
reporters: [
'default',
'jest-junit'
] ]
} }

View File

@ -50,6 +50,7 @@
"get-port": "^4.0.0", "get-port": "^4.0.0",
"glob": "^7.1.3", "glob": "^7.1.3",
"jest": "^23.6.0", "jest": "^23.6.0",
"jest-junit": "^5.2.0",
"jsdom": "^13.0.0", "jsdom": "^13.0.0",
"klaw-sync": "^6.0.0", "klaw-sync": "^6.0.0",
"lerna": "^3.4.3", "lerna": "^3.4.3",

View File

@ -6127,6 +6127,17 @@ jest-jasmine2@^23.6.0:
jest-util "^23.4.0" jest-util "^23.4.0"
pretty-format "^23.6.0" pretty-format "^23.6.0"
jest-junit@^5.2.0:
version "5.2.0"
resolved "https://registry.npmjs.org/jest-junit/-/jest-junit-5.2.0.tgz#980401db7aa69999cf117c6d740a8135c22ae379"
integrity sha512-Mdg0Qpdh1Xm/FA1B/mcLlmEmlr3XzH5pZg7MvcAwZhjHijPRd1z/UwYwkwNHmCV7o4ZOWCf77nLu7ZkhHHrtJg==
dependencies:
jest-config "^23.6.0"
jest-validate "^23.0.1"
mkdirp "^0.5.1"
strip-ansi "^4.0.0"
xml "^1.0.1"
jest-leak-detector@^23.6.0: jest-leak-detector@^23.6.0:
version "23.6.0" version "23.6.0"
resolved "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-23.6.0.tgz#e4230fd42cf381a1a1971237ad56897de7e171de" resolved "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-23.6.0.tgz#e4230fd42cf381a1a1971237ad56897de7e171de"
@ -6262,7 +6273,7 @@ jest-util@^23.4.0:
slash "^1.0.0" slash "^1.0.0"
source-map "^0.6.0" source-map "^0.6.0"
jest-validate@^23.6.0: jest-validate@^23.0.1, jest-validate@^23.6.0:
version "23.6.0" version "23.6.0"
resolved "https://registry.npmjs.org/jest-validate/-/jest-validate-23.6.0.tgz#36761f99d1ed33fcd425b4e4c5595d62b6597474" resolved "https://registry.npmjs.org/jest-validate/-/jest-validate-23.6.0.tgz#36761f99d1ed33fcd425b4e4c5595d62b6597474"
integrity sha512-OFKapYxe72yz7agrDAWi8v2WL8GIfVqcbKRCLbRG9PAxtzF9b1SEDdTpytNDN12z2fJynoBwpMpvj2R39plI2A== integrity sha512-OFKapYxe72yz7agrDAWi8v2WL8GIfVqcbKRCLbRG9PAxtzF9b1SEDdTpytNDN12z2fJynoBwpMpvj2R39plI2A==
@ -11345,6 +11356,11 @@ xml-name-validator@^3.0.0:
resolved "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a" resolved "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a"
integrity sha512-A5CUptxDsvxKJEU3yO6DuWBSJz/qizqzJKOMIfUJHETbBw/sFaDxgd6fxm1ewUaM0jZ444Fc5vC5ROYurg/4Pw== integrity sha512-A5CUptxDsvxKJEU3yO6DuWBSJz/qizqzJKOMIfUJHETbBw/sFaDxgd6fxm1ewUaM0jZ444Fc5vC5ROYurg/4Pw==
xml@^1.0.1:
version "1.0.1"
resolved "https://registry.npmjs.org/xml/-/xml-1.0.1.tgz#78ba72020029c5bc87b8a81a3cfcd74b4a2fc1e5"
integrity sha1-eLpyAgApxbyHuKgaPPzXS0ovweU=
xmlchars@^1.3.1: xmlchars@^1.3.1:
version "1.3.1" version "1.3.1"
resolved "https://registry.npmjs.org/xmlchars/-/xmlchars-1.3.1.tgz#1dda035f833dbb4f86a0c28eaa6ca769214793cf" resolved "https://registry.npmjs.org/xmlchars/-/xmlchars-1.3.1.tgz#1dda035f833dbb4f86a0c28eaa6ca769214793cf"