aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/test_environment.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/test_environment.lua b/test/test_environment.lua
index c781af4b..bc1e5277 100644
--- a/test/test_environment.lua
+++ b/test/test_environment.lua
@@ -533,7 +533,9 @@ function test_env.setup_specs(extra_rocks)
533 end 533 end
534end 534end
535 535
536--- Test if required rock is installed if not, install it 536--- Test if required rock is installed and if not, install it.
537-- Return `true` if the rock is already installed or has been installed successfully,
538-- `false` if installation failed.
537function test_env.need_rock(rock) 539function test_env.need_rock(rock)
538 print("Check if " .. rock .. " is installed") 540 print("Check if " .. rock .. " is installed")
539 if test_env.run.luarocks_noprint_nocov(test_env.quiet("show " .. rock)) then 541 if test_env.run.luarocks_noprint_nocov(test_env.quiet("show " .. rock)) then