diff --git a/.ci/setup_env.sh b/.ci/setup_env.sh index d4005d61..cbebf9ec 100755 --- a/.ci/setup_env.sh +++ b/.ci/setup_env.sh @@ -57,11 +57,10 @@ if [ "$OPENRESTY_TESTS" = true ]; then # ------------------- # Install Test::Nginx # ------------------- - git clone git://github.com/travis-perl/helpers travis-perl-helpers - pushd travis-perl-helpers - source ./init - popd - cpan-install Test::Nginx::Socket + curl -L https://cpanmin.us | perl - App::cpanminus + $PERL_DIR/bin/cpanm local::lib + $PERL_DIR/bin/cpanm Test::Nginx::Socket + echo '[ $SHLVL -eq 1 ] && eval "$(perl -I$PERL_DIR/lib/perl5 -Mlocal::lib)"' >> ~/.bashrc else # ------------------------- # Install test dependencies diff --git a/.travis.yml b/.travis.yml index 471d267f..50536959 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,6 +16,7 @@ env: global: - OPENRESTY=1.9.15.1 - OPENRESTY_DIR=$HOME/openresty + - PERL_DIR=$HOME/perl5 - LUA_DIR=$HOME/lua matrix: - LUA="lua 5.1" @@ -40,5 +41,6 @@ cache: apt: true pip: true directories: + - $PERL_DIR - $OPENRESTY_DIR - $HOME/.ccm/repository/