diff --git a/.gitmodules b/.gitmodules index 4d903c57f..f76a3af9c 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,3 @@ -[submodule "lunit"] - path = lunit - url = https://github.com/ennorehling/lunit.git [submodule "dlmalloc"] path = dlmalloc url = https://github.com/ennorehling/dlmalloc.git diff --git a/clibs b/clibs index abe774f70..484fbf23e 160000 --- a/clibs +++ b/clibs @@ -1 +1 @@ -Subproject commit abe774f70265de14ea7f5e530518ca130562a9c9 +Subproject commit 484fbf23e34f6844f1c4e3f685bb6c53cadf5bfe diff --git a/lunit b/lunit deleted file mode 160000 index 155c96594..000000000 --- a/lunit +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 155c96594435413b4f704eb17558ea0b70631bad diff --git a/s/cmake-init b/s/cmake-init index eea222334..22d98b42e 100755 --- a/s/cmake-init +++ b/s/cmake-init @@ -125,6 +125,7 @@ TOLUA else echo "tolua is $path" fi +luarocks --local install lunitx unset path set -e diff --git a/scripts/eressea/path.lua b/scripts/eressea/path.lua index def970919..085cda997 100644 --- a/scripts/eressea/path.lua +++ b/scripts/eressea/path.lua @@ -3,4 +3,3 @@ if config.paths ~= nil then package.path = package.path .. ';' .. path .. '/?.lua;' .. path .. '/?/init.lua' end end --- print(package.path) diff --git a/scripts/run-tests-e2.lua b/scripts/run-tests-e2.lua index b5f18c7f7..2495b8385 100644 --- a/scripts/run-tests-e2.lua +++ b/scripts/run-tests-e2.lua @@ -4,18 +4,16 @@ path = 'scripts' if config.install then path = config.install .. '/' .. path - package.path = package.path .. ';' .. config.install .. '/lunit/?.lua' - --needed to find lunit if not run from eressea root. Needs right [lua] install setting in eressea.ini (point to eressea root from the start folder) end package.path = package.path .. ';' .. path .. '/?.lua;' .. path .. '/?/init.lua' config.rules = 'e2' +lunit = require 'lunit' require 'eressea' require 'eressea.xmlconf' require 'eressea.path' require 'tests.e2' -require 'lunit' rng.inject(0) eressea.settings.set("rules.food.flags", "4") diff --git a/scripts/run-tests-e3.lua b/scripts/run-tests-e3.lua index 3332df306..e6c8c9186 100644 --- a/scripts/run-tests-e3.lua +++ b/scripts/run-tests-e3.lua @@ -4,18 +4,16 @@ path = 'scripts' if config.install then path = config.install .. '/' .. path - package.path = package.path .. ';' .. config.install .. '/lunit/?.lua' - --needed to find lunit if not run form eressea root. Needs right [lua] install setting in eressea.ini (point to eressea root from the start folder) end package.path = package.path .. ';' .. path .. '/?.lua;' .. path .. '/?/init.lua' config.rules = 'e3' +lunit = require 'lunit' require 'eressea' require 'eressea.path' require 'eressea.xmlconf' require 'tests.e3' -require 'lunit' rng.inject(0) eressea.settings.set("rules.alliances", "0") diff --git a/scripts/run-tests.lua b/scripts/run-tests.lua index d1306ddcd..c14e15a3a 100644 --- a/scripts/run-tests.lua +++ b/scripts/run-tests.lua @@ -4,14 +4,12 @@ path = 'scripts' if config.install then path = config.install .. '/' .. path - package.path = package.path .. ';' .. config.install .. '/lunit/?.lua' - --needed to find lunit if not run form eressea root. Needs right [lua] install setting in eressea.ini (point to eressea root from the start folder) end package.path = package.path .. ';' .. path .. '/?.lua;' .. path .. '/?/init.lua' +lunit = require 'lunit' require 'eressea' require 'eressea.path' require 'tests' -require 'lunit' result = lunit.main() return result.errors + result.failed