Skip to content

test: map treesitter lang to test file#567

Merged
lewis6991 merged 1 commit intonvim-treesitter:masterfrom
PeterCardenas:detect-treesitter-lang
Mar 17, 2025
Merged

test: map treesitter lang to test file#567
lewis6991 merged 1 commit intonvim-treesitter:masterfrom
PeterCardenas:detect-treesitter-lang

Conversation

@PeterCardenas
Copy link
Copy Markdown
Contributor

was trying to update the tests to take advantage of #565, but some of the tests were not being detected correctly. This was due to the filetype not determined by vim.filetype.match, but set to vim.bo.filetype directly. Rather than adding a separate map for the directly set filetypes, I found that I could map treesitter lang to the files it maps to directly. Beyond that, we could use a similar method in this PR to get the injected treesitter languages at cursors in a file to test those as well, but that will be for a future PR, as this one is simply to fix the regression on tests.

@PeterCardenas PeterCardenas force-pushed the detect-treesitter-lang branch from f4a0a3c to c96dd66 Compare March 17, 2025 06:15
@lewis6991 lewis6991 merged commit 83ded3b into nvim-treesitter:master Mar 17, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants