-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.travis.yml
44 lines (39 loc) · 1.51 KB
/
.travis.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
language: cpp
env:
global:
- LUAROCKS=2.3.0
matrix:
- LUA="lua 5.1"
- LUA="lua 5.2"
- LUA="lua 5.3.1"
- LUA="luajit 2.0"
- LUA="luajit @v2.1"
before_install:
- sudo apt-get update
- sudo pip install hererocks
- hererocks here --$LUA --luarocks $LUAROCKS
- eval $(./here/bin/luarocks path --bin)
- bash .travis/setup_rote.sh
- bash .travis/setup_rocks.sh
- sudo apt-get install valgrind ncbi-blast+ libboost-dev
- sudo pip install cpp-coveralls
install:
- luarocks make CFLAGS="-O0 -fPIC -ftest-coverage -fprofile-arcs" LIBFLAG="-shared --coverage"
script:
- luacheck `find src -name '*.lua'`
- tar -cf /tmp/lua-src.tar.gz src/npge/*.lua src/npge/*/*.lua
- rm src/npge/*.lua src/npge/*/*.lua
- export LD_PRELOAD=/lib/x86_64-linux-gnu/libpthread.so.0
- lua -lnpge.cpp -e'os.exit()'
- busted -c
- busted --sort -o .appveyor/busted-print.lua
- LOAD_LUACOV=-lluacov busted --sort -o .appveyor/busted-print.lua
- echo 'os.exit = function() end' > exitless-busted
- echo 'require "busted.runner"({ standalone = false, batch = true })' >> exitless-busted
- if [[ "$LUA" != *"luajit"* ]]; then UNDER_VALGRIND=YES valgrind --error-exitcode=1 --leak-check=full --gen-suppressions=all --suppressions=.travis/nsswitch_c_678.supp lua exitless-busted --sort -o .appveyor/busted-print.lua; fi
- sed 's@:.*/npge/@:.//src/npge/@' -i luacov.stats.out
- luacov
- tar -xf /tmp/lua-src.tar.gz
after_success:
- coveralls -b . --dump c.report.json
- luacov-coveralls -j c.report.json -v