From 8840171407a17a6237e193fde3d6a3cc8aee1c4e Mon Sep 17 00:00:00 2001 From: Hisham Muhammad <hisham@gobolinux.org> Date: Fri, 7 Sep 2018 01:07:38 +0300 Subject: write_rockspec, init: rename --lua-version to --lua-versions Fixes conflict between the use of --lua-version in write_rockspec to list supported Lua versions in a rockspec (now renamed to --lua-versions) and the general --lua-version flag used to select a Lua interpreter. --- spec/write_rockspec_spec.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'spec') diff --git a/spec/write_rockspec_spec.lua b/spec/write_rockspec_spec.lua index 1fb53547..35870775 100644 --- a/spec/write_rockspec_spec.lua +++ b/spec/write_rockspec_spec.lua @@ -56,14 +56,14 @@ describe("LuaRocks write_rockspec tests #integration", function() it("runs with format flag", function() finally(function() os.remove("testrock-dev-1.rockspec") end) - assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --rockspec-format=1.1 --lua-version=5.1,5.2")) + assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --rockspec-format=1.1 --lua-versions=5.1,5.2")) assert.is.truthy(lfs.attributes("testrock-dev-1.rockspec")) -- TODO check contents end) it("runs with full flags", function() finally(function() os.remove("testrock-dev-1.rockspec") end) - assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --lua-version=5.1,5.2 --license=\"MIT/X11\" " + assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --lua-versions=5.1,5.2 --license=\"MIT/X11\" " .. " --homepage=\"http://www.luarocks.org\" --summary=\"A package manager for Lua modules\" ")) assert.is.truthy(lfs.attributes("testrock-dev-1.rockspec")) -- TODO check contents @@ -71,7 +71,7 @@ describe("LuaRocks write_rockspec tests #integration", function() it("with various flags", function() finally(function() os.remove("testrock-dev-1.rockspec") end) - assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --lib=fcgi --license=\"3-clause BSD\" " .. "--lua-version=5.1,5.2")) + assert.is_true(run.luarocks_bool("write_rockspec git://localhost/testrock --lib=fcgi --license=\"3-clause BSD\" " .. "--lua-versions=5.1,5.2")) assert.is.truthy(lfs.attributes("testrock-dev-1.rockspec")) -- TODO check contents end) @@ -88,14 +88,14 @@ describe("LuaRocks write_rockspec tests #integration", function() it("via http", function() finally(function() os.remove("an_upstream_tarball-0.1-1.rockspec") end) - assert.is_true(run.luarocks_bool("write_rockspec http://localhost:8080/file/an_upstream_tarball-0.1.tar.gz --lua-version=5.1")) + assert.is_true(run.luarocks_bool("write_rockspec http://localhost:8080/file/an_upstream_tarball-0.1.tar.gz --lua-versions=5.1")) assert.is.truthy(lfs.attributes("an_upstream_tarball-0.1-1.rockspec")) -- TODO check contents end) it("with a different basedir", function() finally(function() os.remove("renamed_upstream_tarball-0.1-1.rockspec") end) - assert.is_true(run.luarocks_bool("write_rockspec http://localhost:8080/file/renamed_upstream_tarball-0.1.tar.gz --lua-version=5.1")) + assert.is_true(run.luarocks_bool("write_rockspec http://localhost:8080/file/renamed_upstream_tarball-0.1.tar.gz --lua-versions=5.1")) assert.is.truthy(lfs.attributes("renamed_upstream_tarball-0.1-1.rockspec")) -- TODO check contents end) -- cgit v1.2.3-55-g6feb