azure-pipelines.yml 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. jobs:
  2. - job: linux
  3. displayName: 'Linux'
  4. pool:
  5. # List of available software on this image:
  6. # https://github.com/Microsoft/azure-pipelines-image-generation/blob/master/images/linux/Ubuntu1604-README.md
  7. vmImage: 'ubuntu-16.04'
  8. strategy:
  9. matrix:
  10. 'Python 2.7':
  11. # Tests are failing on Python 2.7.0 with the exception
  12. # "TypeError: argument can't be <type 'unicode'>"
  13. YCM_PYTHON_VERSION: '2.7.1'
  14. 'Python 3.5':
  15. YCM_PYTHON_VERSION: '3.5.1'
  16. maxParallel: 2
  17. variables:
  18. COVERAGE: true
  19. # Cannot take advantage of the UsePythonVersion task because headers are
  20. # missing from the provided Python.
  21. steps:
  22. - checkout: self
  23. submodules: recursive
  24. - script: ./azure/linux/install_dependencies.sh
  25. displayName: Install dependencies
  26. - script: ./azure/run_tests.sh
  27. displayName: Run tests
  28. - script: ./azure/send_coverage.sh
  29. displayName: Send coverage
  30. env:
  31. CODECOV_TOKEN: $(CODECOV_TOKEN)
  32. CODECOV_JOB_NAME: '$(Agent.JobName)'
  33. - job: macos
  34. displayName: 'macOS'
  35. pool:
  36. # List of available software on this image:
  37. # https://github.com/Microsoft/azure-pipelines-image-generation/blob/master/images/macos/macos-10.13-Readme.md
  38. vmImage: 'macOS-10.13'
  39. strategy:
  40. matrix:
  41. 'Python 2.7':
  42. # Prior versions fail to compile with error "ld: library not found for
  43. # -lSystemStubs"
  44. YCM_PYTHON_VERSION: '2.7.2'
  45. 'Python 3.5':
  46. YCM_PYTHON_VERSION: '3.5.1'
  47. maxParallel: 2
  48. variables:
  49. COVERAGE: true
  50. steps:
  51. - checkout: self
  52. submodules: recursive
  53. - script: ./azure/macos/install_dependencies.sh
  54. displayName: Install dependencies
  55. - script: ./azure/run_tests.sh
  56. displayName: Run tests
  57. - script: ./azure/send_coverage.sh
  58. displayName: Send coverage
  59. env:
  60. CODECOV_TOKEN: $(CODECOV_TOKEN)
  61. CODECOV_JOB_NAME: '$(Agent.JobName)'
  62. - job: windows
  63. displayName: Windows
  64. pool:
  65. # List of available software on this image:
  66. # https://github.com/Microsoft/azure-pipelines-image-generation/blob/master/images/win/Vs2017-Server2016-Readme.md
  67. vmImage: 'vs2017-win2016'
  68. strategy:
  69. matrix:
  70. # We only test Python 2.7 on 64-bit.
  71. 'Python 2.7 64-bit':
  72. YCM_PYTHON_VERSION: '2.7'
  73. YCM_ARCH: x64
  74. 'Python 3.7 32-bit':
  75. YCM_PYTHON_VERSION: '3.7'
  76. YCM_ARCH: x86
  77. 'Python 3.7 64-bit':
  78. YCM_PYTHON_VERSION: '3.7'
  79. YCM_ARCH: x64
  80. maxParallel: 3
  81. variables:
  82. COVERAGE: true
  83. steps:
  84. - checkout: self
  85. submodules: recursive
  86. # See https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/tool/use-python-version?view=azure-devops
  87. # for a description of this task.
  88. - task: UsePythonVersion@0
  89. inputs:
  90. versionSpec: '$(YCM_PYTHON_VERSION)'
  91. architecture: '$(YCM_ARCH)'
  92. - script: pip install -r python/test_requirements.txt
  93. displayName: Install dependencies
  94. - script: python run_tests.py
  95. displayName: Run tests
  96. - script: codecov --name "$(Agent.JobName)"
  97. displayName: Send coverage
  98. env:
  99. CODECOV_TOKEN: $(CODECOV_TOKEN)