Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lua5.1 compatibility #89

Merged
merged 9 commits into from
Aug 13, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 7 additions & 14 deletions ci-lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,17 @@

. ./config

rm -rf "$TEST_OUT_DIR/lua"
mkdir -p "$TEST_OUT_DIR/lua"
LUA_OUT_DIR="${TEST_OUT_DIR}/lua"

rm -rf "${LUA_OUT_DIR}"
mkdir -p "${LUA_OUT_DIR}"

export LUA_PATH="$LUA_PATH;$LUA_RUNTIME_DIR/?.lua;spec/lua/?.lua;spec/lua/extra/?.lua;compiled/lua/?.lua;;"

# Add `lua_install` dir to PATH, as this is where hererocks installs Lua at CI
export PATH=$PATH:$PWD/../lua_install/bin

# Detect lua executable
if lua5.3 -v; then
LUA_BIN=lua5.3
elif lua -v; then
LUA_BIN=lua
else
echo "Unable to detect lua executable, bailing out :("
exit 1
fi
Comment on lines -15 to -20
Copy link
Member

@generalmimon generalmimon Aug 13, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this check should be kept. If there is no lua executable, there's no point in doing anything else.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Almost none of the others ci-* scripts has this, so I don't see the point?


"$LUA_BIN" spec/lua/run_test_suite.lua -v -o junit -n "$TEST_OUT_DIR/lua/report"
lua spec/lua/run_test_suite.lua --output junit --name "${LUA_OUT_DIR}/report"

./kst-adoption-report lua
aggregate/convert_to_json lua "$TEST_OUT_DIR/lua" "$TEST_OUT_DIR/lua/ci.json"
aggregate/convert_to_json lua "${LUA_OUT_DIR}" "${LUA_OUT_DIR}/ci.json"
2 changes: 1 addition & 1 deletion run-lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

export LUA_PATH="$LUA_PATH;$LUA_RUNTIME_DIR/?.lua;spec/lua/?.lua;spec/lua/extra/?.lua;compiled/lua/?.lua;;"

lua5.3 spec/lua/run_test_suite.lua -v
lua spec/lua/run_test_suite.lua -v
2 changes: 1 addition & 1 deletion spec/lua/run_test_suite.lua

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.