aboutsummaryrefslogtreecommitdiff
path: root/spec/install_spec.lua
diff options
context:
space:
mode:
Diffstat (limited to 'spec/install_spec.lua')
-rw-r--r--spec/install_spec.lua21
1 files changed, 11 insertions, 10 deletions
diff --git a/spec/install_spec.lua b/spec/install_spec.lua
index 0e406e22..0b2ffb53 100644
--- a/spec/install_spec.lua
+++ b/spec/install_spec.lua
@@ -83,23 +83,24 @@ describe("LuaRocks install tests #blackbox #b_install", function()
83 end) 83 end)
84 84
85 it("LuaRocks install only-deps of luasocket packed rock", function() 85 it("LuaRocks install only-deps of luasocket packed rock", function()
86 assert.is_true(test_env.need_luasocket()) 86 assert.is_true(run.luarocks_bool("build --pack-binary-rock luasocket"))
87 local output = run.luarocks("install --only-deps " .. testing_paths.testing_cache .. "/luasocket-3.0rc1-1." .. test_env.platform .. ".rock") 87 local output = run.luarocks("install --only-deps " .. "luasocket-3.0rc1-1." .. test_env.platform .. ".rock")
88 assert.are.same(output, "Successfully installed dependencies for luasocket 3.0rc1-1") 88 assert.are.same(output, "Successfully installed dependencies for luasocket 3.0rc1-1")
89 assert.is_true(os.remove("luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
90 end)
91
92 it("LuaRocks install reinstall", function()
93 assert.is_true(run.luarocks_bool("build --pack-binary-rock luasocket"))
94 assert.is_true(run.luarocks_bool("install " .. "luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
95 assert.is_true(run.luarocks_bool("install --deps-mode=none " .. "luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
96 assert.is_true(os.remove("luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
89 end) 97 end)
90 98
91 it("LuaRocks install binary rock of cprint", function() 99 it("LuaRocks install binary rock of cprint", function()
92 assert.is_true(test_env.need_luasocket())
93 assert.is_true(run.luarocks_bool("build --pack-binary-rock cprint")) 100 assert.is_true(run.luarocks_bool("build --pack-binary-rock cprint"))
94 assert.is_true(run.luarocks_bool("install cprint-0.1-2." .. test_env.platform .. ".rock")) 101 assert.is_true(run.luarocks_bool("install cprint-0.1-2." .. test_env.platform .. ".rock"))
95 assert.is_true(os.remove("cprint-0.1-2." .. test_env.platform .. ".rock")) 102 assert.is_true(os.remove("cprint-0.1-2." .. test_env.platform .. ".rock"))
96 end) 103 end)
97
98 it("LuaRocks install reinstall", function()
99 assert.is_true(test_env.need_luasocket())
100 assert.is_true(run.luarocks_bool("install " .. testing_paths.testing_cache .. "/luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
101 assert.is_true(run.luarocks_bool("install --deps-mode=none " .. testing_paths.testing_cache .. "/luasocket-3.0rc1-1." .. test_env.platform .. ".rock"))
102 end)
103 end) 104 end)
104 105
105 describe("New install functionality based on pull request 552", function() 106 describe("New install functionality based on pull request 552", function()