diff options
author | Adam Harrison <adamdharrison@gmail.com> | 2023-01-13 14:47:00 -0500 |
---|---|---|
committer | Adam Harrison <adamdharrison@gmail.com> | 2023-01-13 14:47:00 -0500 |
commit | 17ce7c5ee47b4febde65d571993d4c963d85fcc1 (patch) | |
tree | 789075caebcd656fd8ec96fad818e861114abd67 /t/run.lua | |
parent | 9424e382ece5181f00f70f79219e3248a468eeaa (diff) | |
download | lite-xl-plugin-manager-17ce7c5ee47b4febde65d571993d4c963d85fcc1.tar.gz lite-xl-plugin-manager-17ce7c5ee47b4febde65d571993d4c963d85fcc1.zip |
Updated it so that lpm can run tests.
Diffstat (limited to 't/run.lua')
-rw-r--r-- | t/run.lua | 13 |
1 files changed, 5 insertions, 8 deletions
@@ -85,10 +85,6 @@ local tests = { end } - - - - local last_command_result, last_command lpm = function(cmd) last_command = "./lpm --quiet --json --userdir=" .. userdir .. " " .. cmd @@ -121,12 +117,14 @@ local function run_tests(tests, arg) local failed = false xpcall(v, function(err) print("[FAIL]: " .. debug.traceback(err, 2)) - print() - print() if last_command then print("Last Command: " .. last_command) - print(json.encode(last_command_result)) + if last_command_result then + print(json.encode(last_command_result)) + end end + print() + print() fail_count = fail_count + 1 failed = true end) @@ -137,5 +135,4 @@ local function run_tests(tests, arg) os.exit(fail_count) end - run_tests(tests, arg) |