lux-cli-help-test(1)

πŸ“¦ version 0.48.0, in nixpkgs unstable

πŸ’… lux-cli-help-test(1) β€” like, the whole manual, but make it make sense

okay bestie, welcome to the lux-cli-help-test page from the General Commands Manual, and no I'm not gonna make you read it alone 🫢


✨ NAME ✨

lux-cli-help-test β€” run the test suite in the current project directory. that's it, that's the vibe πŸŽ€

Lux supports the following test backends, and you tell it which one you want with the [test] table in the lux.toml. slay, let's meet them:

  • busted β€” the classic πŸ’…

https://lunarmodules.github.io/busted/

Example:

[test]
type = "busted"
flags = [ ] # Optional CLI flags to pass to busted

lx test will default to using busted if no test backend is specified and:

  • there is a .busted file in the project root
  • or busted is one of the test_dependencies
  • busted-nlua β€” ngl this one's iconic: it's a build backend for running busted tests with Neovim as the Lua interpreter. used for testing Neovim plugins 🧚

Example:

[test]
type = "busted-nlua"
flags = [ ] # Optional CLI flags to pass to busted

lx test will default to using busted-nlua if no test backend is specified and:

  • there is a .busted file in the project root
  • or busted and nlua are test_dependencies
  • command β€” literally just the name/file name of a shell command that will run the test suite πŸ”₯

Example:

[test]
type = "command"
command = "make"
flags = [ "test" ]
  • script β€” a relative path to a Lua script that will run the test suite 🌸

Example:

[test]
type = "script"
script = "tests.lua" # Expects a tests.lua file in the project root
flags = [ ] # Optional arguments passed to the test script

⭐ SYNOPSIS ⭐

short and sweet, the way we like it:

lux-cli help test

πŸ¦‹ DESCRIPTION πŸ¦‹

Run the test suite in the current project directory. (yes, again β€” it's important 😭)

Lux supports the following test backends, specified by the [test] table in the lux.toml:

  • busted πŸ’–

https://lunarmodules.github.io/busted/

Example:

[test]
type = "busted"
flags = [ ] # Optional CLI flags to pass to busted

lx test will default to using busted if no test backend is specified and:

  • there is a .busted file in the project root
  • or busted is one of the test_dependencies
  • busted-nlua 🌈

A build backend for running busted tests with Neovim as the Lua interpreter. Used for testing Neovim plugins.

Example:

[test]
type = "busted-nlua"
flags = [ ] # Optional CLI flags to pass to busted

lx test will default to using busted-nlua if no test backend is specified and:

  • there is a .busted file in the project root
  • or busted and nlua are test_dependencies
  • command πŸ‘‘

Name/file name of a shell command that will run the test suite.

Example:

[test]
type = "command"
command = "make"
flags = [ "test" ]
  • script πŸ“

Relative path to a Lua script that will run the test suite.

Example:

[test]
type = "script"
script = "tests.lua" # Expects a tests.lua file in the project root
flags = [ ] # Optional arguments passed to the test script
bestie reminder: pick one type in that [test] table or the vibes get chaotic πŸ™ˆ

and that's the whole page, no cap πŸ’œ this little cutie lives in the General Commands Manual under the name lux-cli-help-test(1), it says its source is test, and it's part of the lux-cli-help-test(1) manual β€” so go forth and let your tests slay βœ¨πŸŽ€

πŸ“¦ where this page comes from