azure-pipelines.yml 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. trigger:
  2. - master
  3. pr:
  4. autoCancel: true
  5. branches:
  6. include:
  7. - master
  8. jobs:
  9. - job: WhatsNewUpdate
  10. displayName: '1. What s New Update'
  11. pool:
  12. vmImage: 'Ubuntu-16.04'
  13. demands: npm
  14. steps:
  15. - task: Npm@1
  16. displayName: 'npm install'
  17. inputs:
  18. workingDir: Tools/Gulp
  19. verbose: false
  20. - script: 'gulp tests-whatsnew --max-old-space-size=8192'
  21. workingDirectory: Tools/Gulp
  22. displayName: 'Whats new'
  23. env:
  24. AZURE_PULLREQUESTID: $(System.PullRequest.PullRequestId)
  25. BROWSER_STACK_USERNAME: $(babylon.browserStack.userName)
  26. - job: DocumentationCheck
  27. displayName: '2. Documentation Check'
  28. pool:
  29. vmImage: 'Ubuntu-16.04'
  30. demands: npm
  31. steps:
  32. - task: Npm@1
  33. displayName: 'npm install'
  34. inputs:
  35. workingDir: Tools/Gulp
  36. verbose: false
  37. - script: 'gulp typedoc-check --max-old-space-size=8192'
  38. workingDirectory: Tools/Gulp
  39. displayName: 'Typedoc check'
  40. - job: Linting
  41. displayName: '3. Linting'
  42. pool:
  43. vmImage: 'Ubuntu-16.04'
  44. demands: npm
  45. steps:
  46. - task: Npm@1
  47. displayName: 'npm install'
  48. inputs:
  49. workingDir: Tools/Gulp
  50. verbose: false
  51. - script: 'gulp fullLint --max-old-space-size=8192'
  52. workingDirectory: Tools/Gulp
  53. displayName: 'Full Lint'
  54. - job: Build
  55. displayName: '4. Build and Unit Tests'
  56. pool:
  57. vmImage: 'Ubuntu-16.04'
  58. demands: npm
  59. steps:
  60. - task: Npm@1
  61. displayName: 'npm install'
  62. inputs:
  63. workingDir: Tools/Gulp
  64. verbose: false
  65. - script: 'gulp typescript-all --max-old-space-size=8192'
  66. workingDirectory: Tools/Gulp
  67. displayName: 'Typescript all'
  68. - script: 'gulp tests-babylon-unit --max-old-space-size=8192'
  69. workingDirectory: Tools/Gulp
  70. displayName: 'Unit Tests'
  71. - task: PublishTestResults@2
  72. condition: succeededOrFailed()
  73. inputs:
  74. testRunner: JUnit
  75. testResultsFiles: '.temp/testResults/UnitTests.xml'
  76. - job: TestsWebGL1
  77. displayName: '5. Validation Tests WebGL1'
  78. pool:
  79. vmImage: 'Ubuntu-16.04'
  80. demands: npm
  81. steps:
  82. - task: Npm@1
  83. displayName: 'npm install'
  84. inputs:
  85. workingDir: Tools/Gulp
  86. verbose: false
  87. - script: 'gulp typescript-all --max-old-space-size=8192'
  88. workingDirectory: Tools/Gulp
  89. displayName: 'Typescript all'
  90. - script: |
  91. export DISPLAY=:99
  92. Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
  93. sleep 3 # give xvfb some time to start
  94. gulp tests-validation-virtualscreenWebGL1 --max-old-space-size=8192
  95. workingDirectory: Tools/Gulp
  96. displayName: 'Visual Tests'
  97. - task: PublishTestResults@2
  98. condition: succeededOrFailed()
  99. inputs:
  100. testRunner: JUnit
  101. testResultsFiles: '.temp/testResults/ValidationTests1.xml'
  102. - job: TestsWebGL2
  103. displayName: '6. Validation Tests WebGL2'
  104. pool:
  105. vmImage: 'Ubuntu-16.04'
  106. demands: npm
  107. steps:
  108. - task: Npm@1
  109. displayName: 'npm install'
  110. inputs:
  111. workingDir: Tools/Gulp
  112. verbose: false
  113. - script: 'gulp typescript-all --max-old-space-size=8192'
  114. workingDirectory: Tools/Gulp
  115. displayName: 'Typescript all'
  116. - script: |
  117. export DISPLAY=:99
  118. Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
  119. sleep 3 # give xvfb some time to start
  120. gulp tests-validation-virtualscreen --max-old-space-size=8192
  121. workingDirectory: Tools/Gulp
  122. displayName: 'Visual Tests'
  123. - task: PublishTestResults@2
  124. condition: succeededOrFailed()
  125. inputs:
  126. testRunner: JUnit
  127. testResultsFiles: '.temp/testResults/ValidationTests2.xml'
  128. # - script: 'gulp tests-validation-browserstack'
  129. # workingDirectory: Tools/Gulp
  130. # displayName: 'Browser Stack Tests'
  131. # env:
  132. # TRAVIS_BUILD_NUMBER: $(Build.BuildNumber)
  133. # BROWSER_STACK_USERNAME: $(babylon.browserStack.userName)
  134. # BROWSER_STACK_ACCESS_KEY: $(babylon.browserStack.userToken)
  135. - job: ModuleTests
  136. displayName: '7. Module Tests'
  137. pool:
  138. vmImage: 'Ubuntu-16.04'
  139. demands: npm
  140. steps:
  141. - task: Npm@1
  142. displayName: 'npm install'
  143. inputs:
  144. workingDir: Tools/Gulp
  145. verbose: false
  146. - script: 'gulp typescript-all --max-old-space-size=8192'
  147. workingDirectory: Tools/Gulp
  148. displayName: 'Typescript all'
  149. - script: 'gulp tests-modules'
  150. workingDirectory: Tools/Gulp
  151. displayName: 'Tests modules'
  152. - script: 'sudo gulp localdev-es6 --max-old-space-size=8192'
  153. workingDirectory: Tools/Gulp
  154. displayName: 'Npm link ES6'
  155. - script: 'gulp tests-es6Modules --max-old-space-size=8192'
  156. workingDirectory: Tools/Gulp
  157. displayName: 'Tests ES6'
  158. - task: PublishTestResults@2
  159. condition: succeededOrFailed()
  160. inputs:
  161. testRunner: JUnit
  162. testResultsFiles: '.temp/testResults/ModuleTestsVanilla.xml'
  163. - task: PublishTestResults@2
  164. condition: succeededOrFailed()
  165. inputs:
  166. testRunner: JUnit
  167. testResultsFiles: '.temp/testResults/ModuleTestsWebpack.xml'
  168. - job: ViewerTests
  169. displayName: '8. Viewer Tests'
  170. pool:
  171. vmImage: 'Ubuntu-16.04'
  172. demands: npm
  173. steps:
  174. - task: Npm@1
  175. displayName: 'npm install'
  176. inputs:
  177. workingDir: Tools/Gulp
  178. verbose: false
  179. - script: 'gulp typescript-all --max-old-space-size=8192'
  180. workingDirectory: Tools/Gulp
  181. displayName: 'Typescript all'
  182. - script: 'gulp tests-viewer-unit --max-old-space-size=8192'
  183. workingDirectory: Tools/Gulp
  184. displayName: 'Unit Tests'
  185. - task: PublishTestResults@2
  186. condition: succeededOrFailed()
  187. inputs:
  188. testRunner: JUnit
  189. testResultsFiles: '.temp/testResults/ViewerUnitTests.xml'
  190. - script: |
  191. export DISPLAY=:99
  192. Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
  193. sleep 3 # give xvfb some time to start
  194. gulp tests-viewer-validation-virtualscreen --max-old-space-size=8192
  195. workingDirectory: Tools/Gulp
  196. displayName: 'Visual Tests'
  197. - task: PublishTestResults@2
  198. condition: succeededOrFailed()
  199. inputs:
  200. testRunner: JUnit
  201. testResultsFiles: '.temp/testResults/ViewerValidationTests.xml'