A fast test runner that works out of the box with zero dependencies.
Rust
0
46 commits
updated Sep 30, 2026
A fast test runner that works out of the box. Zero dependencies.
$ testbox - <<EOF
test("just a test", function()
expect_equal(2, 1 + 1)
end)
test("this will fail!", function()
expect_equal(1, 2)
end)
EOF
# Prints out:
✅ just a test
❌ this will fail!
Not equal!
Left: 1
Right: 2
If you have cargo/rust on your system:
$ cargo install testbox
...
$ testbox --version
Otherwise you can just download the compiled executable from the releases page.
$ testbox - <<EOF
test("API test: get users", function()
exec_bg("cd path/to/my/app ; npm run dev", {
wait = function(stdout, stderr)
return string.match(stdout, "Server is ready") ~= nil
end
})
local response = fetch({
url = "http://localhost:3000/api/users",
method = "GET",
})
expect_equal(response.json.users[1].email, "someuser@example.com")
end)
EOF
testbox - <<EOF
test("uppercase text with awk", function()
expect_equal(
exec([[echo foobar | awk '{print toupper($0)}']]).output,
"FOOBAR",
)
end)
EOF
The examples above use helper functions such as exec_bg and fetch. These functions are part of the Testbox Library, which you can learn more about here.
Rust
74.9%
Lua
22.5%
Shell
2.6%
A fast test runner that works out of the box with zero dependencies.
Rust
0
46 commits
updated Sep 30, 2026
A fast test runner that works out of the box. Zero dependencies.
$ testbox - <<EOF
test("just a test", function()
expect_equal(2, 1 + 1)
end)
test("this will fail!", function()
expect_equal(1, 2)
end)
EOF
# Prints out:
✅ just a test
❌ this will fail!
Not equal!
Left: 1
Right: 2
If you have cargo/rust on your system:
$ cargo install testbox
...
$ testbox --version
Otherwise you can just download the compiled executable from the releases page.
$ testbox - <<EOF
test("API test: get users", function()
exec_bg("cd path/to/my/app ; npm run dev", {
wait = function(stdout, stderr)
return string.match(stdout, "Server is ready") ~= nil
end
})
local response = fetch({
url = "http://localhost:3000/api/users",
method = "GET",
})
expect_equal(response.json.users[1].email, "someuser@example.com")
end)
EOF
testbox - <<EOF
test("uppercase text with awk", function()
expect_equal(
exec([[echo foobar | awk '{print toupper($0)}']]).output,
"FOOBAR",
)
end)
EOF
The examples above use helper functions such as exec_bg and fetch. These functions are part of the Testbox Library, which you can learn more about here.
Rust
74.9%
Lua
22.5%
Shell
2.6%