forked from knyar/nginx-lua-prometheus
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
42 lines (38 loc) · 1.23 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
# Stolen from https://github.com/daurnimator/luatz/blob/master/.travis.yml
sudo: false
notifications:
email:
on_success: change
on_failure: always
jobs:
include:
- language: golang
go: "1.14"
services:
- docker
before_install:
- cd integration && go get
script:
- ./test.sh
after_success: []
- env:
- LUA="lua 5.1"
- env:
- LUA="lua 5.2"
language: python
before_install:
- pip install hererocks
- hererocks here -r^ --$LUA # Install latest LuaRocks version
# plus the Lua version for this build job
# into 'here' subdirectory
- export PATH=$PATH:$PWD/here/bin # Add directory with all installed binaries to PATH
- eval `luarocks path --bin`
- luarocks install luacheck
- luarocks install luacov-coveralls
- luarocks install luaunit
script:
- luacheck --globals ngx -- prometheus.lua prometheus_keys.lua prometheus_resty_counter.lua
- luacheck --globals luaunit ngx TestPrometheus TestKeyIndex -- prometheus_test.lua
- lua -lluacov prometheus_test.lua
after_success:
- luacov-coveralls --include %./prometheus.lua --include %./prometheus_keys.lua --include %./prometheus_resty_counter.lua