From 3892b1a9a16ca0edd3de92719cd81bd4fcc63ad4 Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Thu, 25 Aug 2022 16:19:56 -0300 Subject: tests: run full tests with LuaSec --- spec/util/test_env.lua | 13 ++++++++----- spec/util/versions.lua | 1 + 2 files changed, 9 insertions(+), 5 deletions(-) (limited to 'spec') diff --git a/spec/util/test_env.lua b/spec/util/test_env.lua index 1d67d30d..44021147 100644 --- a/spec/util/test_env.lua +++ b/spec/util/test_env.lua @@ -1019,14 +1019,19 @@ function test_env.main() local rocks = {} -- names of rocks, required for building environment local urls = {} -- names of rock and rockspec files to be downloaded + local env_vars = { + LUAROCKS_CONFIG = test_env.testing_paths.testrun_dir .. "/testing_config.lua" + } + if test_env.TYPE_TEST_ENV == "full" then table.insert(urls, "/luafilesystem-${LUAFILESYSTEM}.src.rock") table.insert(urls, "/luasocket-${LUASOCKET}.src.rock") table.insert(urls, "/luasocket-${LUASOCKET}.rockspec") + table.insert(urls, "/luasec-${LUASEC}.src.rock") table.insert(urls, "/md5-1.2-1.src.rock") table.insert(urls, "/manifests/hisham/lua-zlib-1.2-0.src.rock") table.insert(urls, "/manifests/hisham/lua-bz2-0.2.1.1-1.src.rock") - rocks = {"luafilesystem", "luasocket", "md5", "lua-zlib", "lua-bz2"} + rocks = {"luafilesystem", "luasocket", "luasec", "md5", "lua-zlib", "lua-bz2"} if test_env.TEST_TARGET_OS ~= "windows" then if test_env.lua_version == "5.1" then table.insert(urls, "/bit32-${BIT32}.src.rock") @@ -1035,6 +1040,8 @@ function test_env.main() table.insert(urls, "/luaposix-${LUAPOSIX}.src.rock") table.insert(rocks, "luaposix") end + assert(test_env.run.luarocks_nocov("config variables.OPENSSL_INCDIR " .. Q(test_env.OPENSSL_INCDIR), env_vars)) + assert(test_env.run.luarocks_nocov("config variables.OPENSSL_LIBDIR " .. Q(test_env.OPENSSL_LIBDIR), env_vars)) end -- luacov is needed for both minimal or full environment @@ -1049,10 +1056,6 @@ function test_env.main() lfs.mkdir(testing_paths.testing_server) download_rocks(urls, testing_paths.testing_server) - local env_vars = { - LUAROCKS_CONFIG = test_env.testing_paths.testrun_dir .. "/testing_config.lua" - } - build_environment(rocks, env_vars) prepare_mock_server_binary_rocks() diff --git a/spec/util/versions.lua b/spec/util/versions.lua index 0d3b8796..1b227e4b 100644 --- a/spec/util/versions.lua +++ b/spec/util/versions.lua @@ -11,6 +11,7 @@ return { luafilesystem_old = "1.6.3-2", luaposix = "35.1-1", luasocket = "3.0.0-1", + luasec = "1.2.0-1", lxsh = "0.8.6-2", timerwheel = "0.2.0-2", -- dependency for copas } -- cgit v1.2.3-55-g6feb