test_windows.yml 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. name: windows
  2. on:
  3. workflow_call:
  4. inputs:
  5. build_flags:
  6. type: string
  7. functionaltest_timeout:
  8. default: 20
  9. type: number
  10. workflow_dispatch:
  11. jobs:
  12. windows:
  13. runs-on: windows-2022
  14. timeout-minutes: 45
  15. strategy:
  16. fail-fast: false
  17. matrix:
  18. test: [functional, old]
  19. steps:
  20. - uses: actions/checkout@v4
  21. - uses: ./.github/actions/setup
  22. - name: Build deps
  23. run: |
  24. cmake -S cmake.deps -B .deps -G Ninja -D CMAKE_BUILD_TYPE='RelWithDebInfo'
  25. cmake --build .deps
  26. - name: Build
  27. run: |
  28. cmake --preset ci -D CMAKE_BUILD_TYPE='RelWithDebInfo' ${{ inputs.build_flags }}
  29. cmake --build build
  30. - name: Install test deps
  31. run: |
  32. $PSNativeCommandArgumentPassing = 'Legacy'
  33. & build\bin\nvim.exe "--version"
  34. # Ensure that the "win32" feature is set.
  35. & build\bin\nvim -u NONE --headless -c 'exe !has(\"win32\").\"cq\"'
  36. python -m pip install pynvim
  37. # Sanity check
  38. python -c "import pynvim; print(str(pynvim))"
  39. node --version
  40. npm.cmd --version
  41. npm.cmd install -g neovim
  42. Get-Command -CommandType Application neovim-node-host.cmd
  43. npm.cmd link neovim
  44. - if: ${{ matrix.test == 'functional' }}
  45. name: functionaltest
  46. timeout-minutes: ${{ inputs.functionaltest_timeout }}
  47. run: cmake --build build --target functionaltest
  48. - if: ${{ matrix.test == 'old' }}
  49. uses: msys2/setup-msys2@v2
  50. with:
  51. update: true
  52. install: unzip
  53. pacboy: >-
  54. make:p gcc:p diffutils:p
  55. release: false
  56. - if: ${{ matrix.test == 'old' }}
  57. name: oldtest
  58. shell: msys2 {0}
  59. run: |
  60. cd test/old/testdir
  61. mingw32-make VERBOSE=1