-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
request: improve the testing section by adding minimal, concrete steps #10
Comments
Also related vhyrro/luarocks.nvim#12, if lua specifc instructions are deemed necessary, a workaround could be added to this issue (I don't know what one would be right now) |
Hey again 😄
Typically, if a plugin isn't on luarocks, I
Another option is to add a rockspec and use
I think
This, too, is probably better kept in the
I would rather see this in the
Not strictly. It just makes it more convenient, because it translates Lua's CLI to Neovim's. |
In principle, the lua version used with the luarocks installation shouldn't matter. |
For future reference, I finally did the conversion in my project. The change can be found here mikavilpas/yazi.nvim#113 (in case technical details might be useful for others) Really happy with the results, by the way! 🙏🏻
|
I'm spending some time going through the suggestions in the testing section. I think the recommendation to move from
plenary.test
to busted sounds good, and it doesn't seem too complicated since it's apparently a superset of what my plugin is already using.I also love the recommendation on using luarocks. I built my own hacky system that uses lazy.nvim to set up tests (it uses its own
lazy-lock.json
that I commit to the repository), but I will see if I can move to using luarocks instead.I'm not sure what the status in the neovim plugin ecosystem is on using luarocks, so that's why I picked lazy.nvim because it can work with everything (including specific git branches, tags, commits etc).
I'm looking for clarification on a few things that might also be good candidates to add to the guide if you feel like it:
As a plugin author, https://mrcjkb.dev/posts/2023-06-06-luarocks-test.html seems like a short and "to the point" guide. Do you think it could be highlighted so that it's easier to see? Currently it is the second item.
The instruction to
...use [busted](https://github.com/lunarmodules/busted) for testing, which is a lot more powerful.
is good, but it's a bit of reading 😅... I think it would be very effective to have a list of concrete actions on how busted should be set up:as a beginner plugin author, what programs should I install to get started?
e.g. "Use the following commands to set up your development environment" (as few lines of text as needed):
how should I structure my project's tests? This PlenaryBusted guide is very succinct and helpful in this regard.
Is nlua required? Do I need it, or can I just get started with neovim instead?
The text was updated successfully, but these errors were encountered: