From 21b08e29ec1d4aa887d61a27b8fa8a75232522af Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Sun, 18 Feb 2024 21:06:10 -0300 Subject: vendor in the dkjson dependency Fixes #1243. Fixes #1168. Fixes #559. --- spec/config_spec.lua | 16 ---------------- spec/upload_spec.lua | 1 - 2 files changed, 17 deletions(-) (limited to 'spec') diff --git a/spec/config_spec.lua b/spec/config_spec.lua index 885b022a..05da0007 100644 --- a/spec/config_spec.lua +++ b/spec/config_spec.lua @@ -23,17 +23,9 @@ describe("LuaRocks config tests #integration", function() end) it("--json", function() - assert.is_true(run.luarocks_nocov("install dkjson")) - finally(function() - assert.is_true(run.luarocks_nocov("remove dkjson")) - end) assert.match('"rocks_servers":[', run.luarocks("config --json"), 1, true) end) - it("--json fails without a json library", function() - assert.falsy(run.luarocks_bool("config --json")) - end) - it("with --tree respects custom config", function() write_file("my_config.lua", [[ rocks_trees = { @@ -167,18 +159,10 @@ describe("LuaRocks config tests #integration", function() end) it("can read as JSON", function() - assert.is_true(run.luarocks_nocov("install dkjson")) - finally(function() - assert.is_true(run.luarocks_nocov("remove dkjson")) - end) local output = run.luarocks("config rocks_trees --json") assert.match('^%["', output) end) - it("--json does not work without a json library", function() - assert.is_false(run.luarocks_bool("config rocks_trees --json")) - end) - it("reads an array -> hash config key", function() local output = run.luarocks("config rocks_trees[2].name") assert.match("[a-z]+", output) diff --git a/spec/upload_spec.lua b/spec/upload_spec.lua index 73f26cd7..119d34b6 100644 --- a/spec/upload_spec.lua +++ b/spec/upload_spec.lua @@ -27,7 +27,6 @@ describe("luarocks upload #integration", function() end) it("force #unix", function() - assert.is_true(test_env.need_rock("dkjson")) assert.is_false(run.luarocks_bool("upload --api-key=\"invalid\" --force " .. testing_paths.testing_server .. "/luasocket-${LUASOCKET}.rockspec")) end) -- cgit v1.2.3-55-g6feb