diff options
Diffstat (limited to 'test/withrepo.lua')
-rw-r--r-- | test/withrepo.lua | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/test/withrepo.lua b/test/withrepo.lua index bf90b0c..0795993 100644 --- a/test/withrepo.lua +++ b/test/withrepo.lua @@ -7,12 +7,15 @@ local _xpcall = xpcall function xpcall(fn, tb) os.execute("rm -rf test/test_repo") + os.execute("rm -rf test/lorries.git") local ok, msg = _xpcall(fn, tb) os.execute("rm -rf test/test_repo") + os.execute("rm -rf test/lorries.git") return ok, msg end -function test_repo() +function test_repo(reponame) + reponame = reponame or "test_repo" os.execute("sh test/create_test_repo.sh") - return assert(require("gall.repository").new "test/test_repo") -end
\ No newline at end of file + return assert(require("gall.repository").new("test/" .. reponame)) +end |