lux-cli-test(1)
π
lux-cli-test(1) β General Commands Manual π
okay bestie, welcome to the lux-cli-test(1) page π this is the whole group-chat rundown, no cap.
π NAME π
lux-cli-test β Run the test suite in the current project directory. fr fr.
Lux supports the following test backends, specified by the [test] table in the lux.toml:
bustedβ the classic. URL: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
.bustedfile in the project root - or
bustedis one of thetest_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
.bustedfile in the project root - or
bustedandnluaaretest_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
β¨ SYNOPSIS β¨
lux-cli test [--impure] [--no-lock] [--server] [--extra-servers]
[-p|--package] [--namespace] [--lua-dir] [--lua-version] [--tree]
[--cache-dir] [--data-dir] [--variables] [--profile] [--verbose]
[--no-progress] [--no-prompt] [--preset] [--nvim] [--no-tfa] [--timeout]
[--max-jobs] [--no-luarc] [--no-wrap-bin] [--user-agent] [-h|--help]
[TEST_ARGS]
π¦ DESCRIPTION π¦
Run the test suite in the current project directory. literally the main character move π
Lux supports the following test backends, specified by the [test] table in the lux.toml:
bustedβ URL: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
.bustedfile in the project root - or
bustedis one of thetest_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
.bustedfile in the project root - or
bustedandnluaaretest_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
π OPTIONS π
--impureβ Don't isolate the user environment (keepHOMEandXDGenvironment variables). π--no-lockβ Ignore the project's lockfile and don't create one. π--server <server>β Fetch rocks/rockspecs from this server (takes priority over config file). π--extra-servers <extra-server>β Fetch rocks/rockspecs from these servers in addition to the main server (overrides any entries in the config file). π-p,--package <PACKAGE>β Package to run tests for. π--namespace <namespace>β Specify the luarocks server namespace to use. π§--lua-dir <prefix>β Specify the directory in which to install Lua if not found. π--lua-version <ver>β Which Lua installation to use. Valid versions are:'5.1','5.2','5.3','5.4','5.5','jit'and'jit52'. If not set, Lux will attempt to detect the Lua version:- From the current project, if it has an exact Lua version requirement.
- From the Lua installation that is available on the
PATH.
--tree <tree>β Which tree to operate on. In a workspace, this can be used to specify a detached workspace tree. π³--cache-dir <cache-dir>β Specifies the cache directory, e.g. for luarocks manifests. ποΈ--data-dir <data-dir>β Specifies the data directory, in which the default user install tree resides (e.g.~/.local/share/lux). π--variables <variable>β Override config variables. Example:lx -v "LUA=/path/to/lua" ...βοΈ--profile <profile>β The build profile to use when compiling packages. Default:release.
Possible values:
releasedev
--verboseβ Display verbose output of commands executed, enabling DEBUG logs. To enable TRACE logs, setRUST_LOG=trace. π--no-progressβ Don't print any progress bars or spinners. π ββοΈ--no-prompt <NO_PROMPT>β Skip prompts, selecting the default option. Prompting is enabled by default in terminal/TTY environments.
Possible values:
truefalse
--preset <preset>β Configure Lux for a specific environment. Valid presets are:'nvim'.
Possible values:
nvim: Configure Lux for Neovim plugins
--nvimβ [DEPRECATED] Configure lux for installing Neovim packages. Use--preset nviminstead. π
β οΈ bestie,--nvimis deprecated β the page says use--preset nviminstead. periodt.
--no-tfaβ Disable prompts for two-factor authentication (2FA) codes. It is strongly recommended to enable 2FA instead see (https://luarocks.org/settings/two-factor-auth). π
β οΈ enabling 2FA is strongly recommended β that's straight from the page, no cap.
--timeout <seconds>β Timeout on network operations, in seconds.0means no timeout (wait forever). Default is 30. β³--max-jobs <MAX_JOBS>β Maximum buffer size for parallel jobs, such as downloading rockspecs and installing rocks.0means no limit. Default is 0. π--no-luarcβ Do not generate or update a.luarc.jsonfile when building a project. π«--no-wrap-binβ Do not wrap Luabinscripts. π--user-agent <USER_AGENT>β The user agent to set when making web requests. Default is"lux/<version>". π-h,--helpβ Print help (see a summary with'-h'). π«Ά[TEST_ARGS]β Extra arguments to pass to the test runner or test script. π
cute little sign-off bestie: this page is lux-cli-test(1) from the test source/version side of the footer, and the footer title is lux-cli-test(1) β there's no date on that footer line, so I'm not inventing one. iykyk πβ¨
π¦ where this page comes from
- nixpkgs unstable: lux-cli 0.48.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms