diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2018-06-19 09:58:36 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2018-07-01 15:51:09 -0300 |
commit | a55f09fae00cb3c575f926eda4d76e81ff37b2ba (patch) | |
tree | c36d2d475549f76805b3b9bfd08f1429f032e5ac /spec/test_spec.lua | |
parent | 392f67d65a950fcf08a08d10d21e80f359160262 (diff) | |
download | luarocks-a55f09fae00cb3c575f926eda4d76e81ff37b2ba.tar.gz luarocks-a55f09fae00cb3c575f926eda4d76e81ff37b2ba.tar.bz2 luarocks-a55f09fae00cb3c575f926eda4d76e81ff37b2ba.zip |
fs: make module loading side-effect free, require explicit init()
Diffstat (limited to 'spec/test_spec.lua')
-rw-r--r-- | spec/test_spec.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/spec/test_spec.lua b/spec/test_spec.lua index 0111f89a..7a2399a9 100644 --- a/spec/test_spec.lua +++ b/spec/test_spec.lua | |||
@@ -82,6 +82,7 @@ end) | |||
82 | test_env.unload_luarocks() | 82 | test_env.unload_luarocks() |
83 | 83 | ||
84 | local fs = require("luarocks.fs") | 84 | local fs = require("luarocks.fs") |
85 | local cfg = require("luarocks.core.cfg") | ||
85 | local path = require("luarocks.path") | 86 | local path = require("luarocks.path") |
86 | local test = require("luarocks.test") | 87 | local test = require("luarocks.test") |
87 | local test_busted = require("luarocks.test.busted") | 88 | local test_busted = require("luarocks.test.busted") |
@@ -91,6 +92,8 @@ describe("LuaRocks test #unit", function() | |||
91 | local runner | 92 | local runner |
92 | 93 | ||
93 | setup(function() | 94 | setup(function() |
95 | cfg.init() | ||
96 | fs.init() | ||
94 | runner = require("luacov.runner") | 97 | runner = require("luacov.runner") |
95 | runner.init(testing_paths.testrun_dir .. "/luacov.config") | 98 | runner.init(testing_paths.testrun_dir .. "/luacov.config") |
96 | runner.tick = true | 99 | runner.tick = true |