-
Notifications
You must be signed in to change notification settings - Fork 1
62 lines (52 loc) · 1.42 KB
/
build_and_test.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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: Build and Test
on: [push]
jobs:
build_and_test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: '3.10'
- name: Install Requirements
run: |
sudo apt-get update
sudo apt-get install lua5.4 liblua5.4-dev make cmake gcc -y
which python3
which lua
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: cpp
queries: security-and-quality
- name: Build
run: |
cmake . -DCMAKE_BUILD_TYPE=Debug
make -j
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
- name: Test (setup)
run: |
cp lib/libpylua.so tests/pylua.so
cd tests
wget https://raw.githubusercontent.com/bluebird75/luaunit/master/luaunit.lua
cd ..
- name: Test
run: |
cd tests
lua test0.lua
lua test1.lua
lua test2.lua
lua test3.lua
lua test4.lua
python3 testA.py
cd ..
- name: Code Coverage (skipping broken)
if : false
run: |
gcov -abcfu CMakeFiles/pylua.dir/src/lua_py.c
gcov -abcfu CMakeFiles/pylua.dir/src/py_lua.c
gcov -abcfu CMakeFiles/pylua.dir/src/convert.c
- name: Upload Code Coverage (skipping broken)
if: false
uses: codecov/codecov-action@v1