microsoft/vscode-react-native
Publicmirrored fromhttps://github.com/microsoft/vscode-react-nativeAvailable
.ci/common-validation.yml
38lines · modecode
| 1 | steps: |
| 2 | - task: NodeTool@0 |
| 3 | displayName: "Use Node 18.x" |
| 4 | inputs: |
| 5 | versionSpec: 18.x |
| 6 | - bash: npm install gulp react-devtools @vscode/vsce -g --force |
| 7 | displayName: "npm install gulp react-devtools @vscode/vsce -g" |
| 8 | - bash: npm ci |
| 9 | displayName: "npm ci" |
| 10 | - bash: npm run build |
| 11 | displayName: "npm run build" |
| 12 | - bash: | |
| 13 | /usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 & |
| 14 | echo ">>> Started xvfb" |
| 15 | displayName: Start xvfb |
| 16 | condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux')) |
| 17 | - bash: "npm test --verbose" |
| 18 | displayName: "Run host tests" |
| 19 | env: |
| 20 | DISPLAY: ":99.0" |
| 21 | - bash: npm run test-localization --verbose |
| 22 | displayName: "Run localization tests" |
| 23 | env: |
| 24 | DISPLAY: ":99.0" |
| 25 | - task: PublishTestResults@2 |
| 26 | displayName: "Publish Extension Test Results" |
| 27 | inputs: |
| 28 | testResultsFiles: test/ExtensionTests.xml |
| 29 | failTaskOnFailedTests: true |
| 30 | testRunTitle: "[Extension Context] $(Agent.OS) React Native unit tests - Attempt №$(System.JobAttempt)" |
| 31 | condition: always() |
| 32 | - task: PublishTestResults@2 |
| 33 | displayName: "Publish Localization Test Results" |
| 34 | inputs: |
| 35 | testResultsFiles: test/LocalizationTests.xml |
| 36 | failTaskOnFailedTests: true |
| 37 | testRunTitle: "[Localization Context] $(Agent.OS) React Native unit tests - Attempt №$(System.JobAttempt)" |
| 38 | condition: always() |
| 39 | |