-
Notifications
You must be signed in to change notification settings - Fork 575
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
37 additions
and
19 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,47 @@ | ||
sudo: required | ||
dist: trusty | ||
|
||
os: linux | ||
dist: xenial | ||
|
||
language: c | ||
|
||
compiler: | ||
- gcc | ||
- clang | ||
sudo: required | ||
|
||
addons: | ||
apt: | ||
packages: | ||
- luarocks | ||
- jq | ||
|
||
- cpanminus | ||
- build-essential | ||
- libncurses5-dev | ||
- libpcre3-dev | ||
- libreadline-dev | ||
- libssl-dev | ||
- perl | ||
- etcd | ||
- luarocks | ||
- cmake | ||
- lua-check | ||
|
||
env: | ||
matrix: | ||
- NGINX_VERSION=1.9.15 | ||
- NGINX_VERSION=1.11.2 | ||
global: | ||
- OPENRESTY_PREFIX=/usr/local/openresty-debug | ||
|
||
before_install: | ||
- jq . conf/orange.conf.example >> /dev/null || exit 1 | ||
- sudo luarocks install luacheck | ||
- luacheck -q . | ||
- '! grep -n -P ''(?<=.{80}).+'' --color `find . -name ''*.lua''` || (echo "ERROR: Found Lua source lines exceeding 80 columns." > /dev/stderr; exit 1)' | ||
- '! grep -n -P ''\t+'' --color `find . -name ''*.lua''` || (echo "ERROR: Cannot use tabs." > /dev/stderr; exit 1)' | ||
- sudo cpanm --notest Test::Nginx IPC::Run > build.log 2>&1 || (cat build.log && exit 1) | ||
|
||
install: | ||
- wget -qO - https://openresty.org/package/pubkey.gpg | sudo apt-key add - | ||
- sudo apt-get -y install software-properties-common | ||
- sudo add-apt-repository -y "deb http://openresty.org/package/ubuntu $(lsb_release -sc) main" | ||
- sudo apt-get update | ||
- sudo apt-get install openresty-debug | ||
- sudo opm --install-dir=./ get zhangbao0325/orangelib | ||
- sudo luarocks install luafilesystem | ||
- sudo luarocks install luasocket | ||
- sudo cd cd conf | ||
- sudo cp orange.conf.example orange.conf | ||
- sudo cp nginx.conf.example nginx.conf | ||
- git clone https://github.com/openresty/test-nginx.git test-nginx | ||
|
||
script: | ||
- sudo service etcd start | ||
- sudo orange start | ||
- export PATH=$OPENRESTY_PREFIX/nginx/sbin:$OPENRESTY_PREFIX/luajit/bin:$PATH | ||
- make check || exit 1 | ||
- prove -Itest-nginx/lib -r t |