Skip to content

Commit d63ce88

Browse files
committed
Merge pull request openresty#43 from chipitsine/master
fixed number of skipped tests, added travis-ci support
2 parents 1294148 + 95453ab commit d63ce88

File tree

2 files changed

+69
-1
lines changed

2 files changed

+69
-1
lines changed

.travis.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
sudo: required
2+
dist: trusty
3+
4+
os: linux
5+
6+
language: c
7+
8+
compiler:
9+
- gcc
10+
- clang
11+
12+
cache:
13+
directories:
14+
- download-cache
15+
16+
env:
17+
global:
18+
- JOBS=3
19+
- NGX_BUILD_JOBS=$JOBS
20+
- LUAJIT_PREFIX=/opt/luajit21
21+
- LUAJIT_LIB=$LUAJIT_PREFIX/lib
22+
- LUAJIT_INC=$LUAJIT_PREFIX/include/luajit-2.1
23+
- LUA_INCLUDE_DIR=$LUAJIT_INC
24+
- LUA_CMODULE_DIR=/lib
25+
- OPENSSL_PREFIX=/opt/ssl
26+
- OPENSSL_LIB=$OPENSSL_PREFIX/lib
27+
- OPENSSL_INC=$OPENSSL_PREFIX/include
28+
- OPENSSL_VER=1.0.2h
29+
- LD_LIBRARY_PATH=$LUAJIT_LIB:$LD_LIBRARY_PATH
30+
- TEST_NGINX_SLEEP=0.006
31+
matrix:
32+
- NGINX_VERSION=1.9.15
33+
# - NGINX_VERSION=1.10.0
34+
35+
install:
36+
- if [ ! -d download-cache ]; then mkdir download-cache; fi
37+
- if [ ! -f download-cache/openssl-$OPENSSL_VER.tar.gz ]; then wget -O download-cache/openssl-$OPENSSL_VER.tar.gz https://www.openssl.org/source/openssl-$OPENSSL_VER.tar.gz; fi
38+
- sudo apt-get install -qq -y cpanminus axel
39+
- sudo cpanm --notest Test::Nginx > build.log 2>&1 || (cat build.log && exit 1)
40+
- wget http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz
41+
- git clone https://github.com/openresty/openresty.git ../openresty
42+
- git clone https://github.com/openresty/nginx-devel-utils.git
43+
- git clone https://github.com/simpl/ngx_devel_kit.git ../ndk-nginx-module
44+
- git clone https://github.com/openresty/lua-nginx-module.git ../lua-nginx-module
45+
- git clone https://github.com/openresty/no-pool-nginx.git ../no-pool-nginx
46+
- git clone https://github.com/openresty/echo-nginx-module.git ../echo-nginx-module
47+
- git clone https://github.com/openresty/lua-resty-lrucache.git
48+
- git clone https://github.com/openresty/headers-more-nginx-module.git ../headers-more-nginx-module
49+
- git clone -b v2.1-agentzh https://github.com/openresty/luajit2.git
50+
51+
script:
52+
- cd luajit2/
53+
- make -j$JOBS CCDEBUG=-g Q= PREFIX=$LUAJIT_PREFIX CC=$CC XCFLAGS='-DLUA_USE_APICHECK -DLUA_USE_ASSERT' > build.log 2>&1 || (cat build.log && exit 1)
54+
- sudo make install PREFIX=$LUAJIT_PREFIX > build.log 2>&1 || (cat build.log && exit 1)
55+
- cd ..
56+
- cd lua-resty-lrucache && sudo make DESTDIR=$LUAJIT_PREFIX LUA_LIB_DIR=/share/lua/5.1 install && cd ..
57+
- tar zxf download-cache/openssl-$OPENSSL_VER.tar.gz
58+
- cd openssl-$OPENSSL_VER/
59+
- ./config shared --prefix=$OPENSSL_PREFIX -DPURIFY > build.log 2>&1 || (cat build.log && exit 1)
60+
- make -j$JOBS > build.log 2>&1 || (cat build.log && exit 1)
61+
- sudo make PATH=$PATH install_sw > build.log 2>&1 || (cat build.log && exit 1)
62+
- cd ..
63+
- export PATH=$PWD/work/nginx/sbin:$PWD/nginx-devel-utils:$PATH
64+
- export NGX_BUILD_CC=$CC
65+
- ngx-build $NGINX_VERSION --with-ipv6 --with-http_realip_module --with-http_ssl_module --with-cc-opt="-I$OPENSSL_INC" --with-ld-opt="-L$OPENSSL_LIB -Wl,-rpath,$OPENSSL_LIB" --add-module=../ndk-nginx-module --add-module=../echo-nginx-module --add-module=../headers-more-nginx-module --add-module=../lua-nginx-module --with-debug > build.log 2>&1 || (cat build.log && exit 1)
66+
- nginx -V
67+
- ldd `which nginx`|grep -E 'luajit|ssl|pcre'
68+
- prove -r t

t/ssl.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -783,7 +783,7 @@ Using IPv6 address: 0.0.0.1
783783
--- no_error_log
784784
[error]
785785
[alert]
786-
--- skip_eval: 3: system("ping6 -c 1 ::1 >/dev/null 2>&1") ne 0
786+
--- skip_eval: 6: system("ping6 -c 1 ::1 >/dev/null 2>&1") ne 0
787787
788788
789789

0 commit comments

Comments
 (0)