-
Notifications
You must be signed in to change notification settings - Fork 62
37 lines (37 loc) · 969 Bytes
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Run luacheck and unit tests
on:
push:
branches:
- master
pull_request:
workflow_dispatch:
jobs:
luacheck:
name: Run luacheck
runs-on: ubuntu-latest
container:
image: ubuntu:latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Install additional packages
run: |
set -ex
apt -qy update
apt -qy install lua-check
- name: Run luacheck
run: luacheck lunamark/
test:
name: Run unit tests
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Build docker image
run: |
set -ex
export DOCKER_BUILDKIT=1
docker build -t jgm/lunamark .
- name: Run unit tests
run: |
docker run --rm -v "$PWD":/mnt -w /mnt --entrypoint /bin/bash jgm/lunamark -c 'set -e; eval "$(luarocks path)"; make testdeps; make test'