tests: compatibility with luarocks test
(#8)
#35
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: [push] | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [macos-latest, ubuntu-latest, windows-latest] | |
lua: ["lua 5.1", "lua 5.2", "lua 5.3", "lua 5.4", "luajit 2.1"] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Install Lua | |
env: | |
# luajit fails to build on macos without this | |
MACOSX_DEPLOYMENT_TARGET: "10.15" | |
run: | | |
python -m pip install hererocks | |
python -m hererocks lua_install --${{ matrix.lua }} -rlatest | |
. lua_install/bin/activate | |
luarocks install busted | |
- name: Build | |
run: | | |
. lua_install/bin/activate | |
luarocks make | |
- name: Test | |
run: | | |
. lua_install/bin/activate | |
luarocks test |