File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 88-- http://sailorproject.org
99---- ----------------------------------------------------------------------------
1010
11- local lfs = require " lfs"
1211local argparse = require " argparse"
1312local colors = require " ansicolors"
1413local actions = require " sailor.cli"
Original file line number Diff line number Diff line change 66-- http://sailorproject.org
77---- ----------------------------------------------------------------------------
88
9+ local lfs = require " lfs"
10+
911local cli = {}
1012
1113local function get_sailor_path (current_dir )
@@ -117,18 +119,18 @@ function cli.start()
117119end
118120
119121function cli .test (args , _ )
120- local ok , code
122+ local ok
121123
122- flags = table.concat (args .EXTRA_FLAGS , " " )
124+ local flags = table.concat (args .EXTRA_FLAGS , " " )
123125
124126 if args .resty then
125- ok , code = os.execute (' resty tests/bootstrap_resty.lua' )
127+ ok = os.execute (' resty tests/bootstrap_resty.lua' )
126128 else
127- ok , code = os.execute (' busted --helper=tests/bootstrap.lua ' .. flags .. ' tests/unit/* tests/functional/*' )
129+ ok = os.execute (' busted --helper=tests/bootstrap.lua ' .. flags .. ' tests/unit/* tests/functional/*' )
128130 end
129131
130132 if type (ok ) == " number" then return ok end -- Lua 5.1 just returns the status code
131- exit_code = ok and 0 or 1 -- don't care about actual value
133+ local exit_code = ok and 0 or 1 -- don't care about actual value
132134
133135 if exit_code and exit_code ~= 0 then
134136 -- exit code sometimes is > 255 and fails to be propagated
You can’t perform that action at this time.
0 commit comments