projekt0n / github-nvim-theme

GitHub's Neovim themes
MIT License
2.11k stars 106 forks source link

test(queries): add tests for queries #301

Closed tmillr closed 9 months ago

tmillr commented 1 year ago

Looks like it requires the compiled language parsers to be available in order to parse a query for a certain lang. This isn't possible in CI unless we changed it to bring in the necessary language parsers before testing. So for now I just put in 2 stopgaps:

  1. Skip query parse test for langs which don't have parsers currently available
  2. Skip all query parse tests if it's not running in nvim 0.9 or later (I don't think nvim 0.8 has the query parsing functions)

But it's not totally useless in CI as it will still test the directory structure of ./queries as well as test the parsing of queries whose ts parsers nvim bundles/ships with (i.e. lua, vim, vimdoc, markdown).