From f91f2cad8362ce2f21c86561269ef1ff1abae817 Mon Sep 17 00:00:00 2001 From: Cory Benfield Date: Wed, 7 Dec 2016 10:19:36 +0000 Subject: [PATCH 1/3] Stop installing/testing nghttp2. --- .travis.yml | 4 ---- .travis/install.sh | 39 --------------------------------------- 2 files changed, 43 deletions(-) diff --git a/.travis.yml b/.travis.yml index e6eb45d4..92512b96 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,15 +11,11 @@ env: - TEST_RELEASE=false HYPER_FAST_PARSE=true - TEST_RELEASE=true HYPER_FAST_PARSE=false - TEST_RELEASE=true HYPER_FAST_PARSE=true - - NGHTTP2=true matrix: allow_failures: - env: TEST_RELEASE=true HYPER_FAST_PARSE=true - env: TEST_RELEASE=true HYPER_FAST_PARSE=false - exclude: - - env: NGHTTP2=true - python: "pypy-5.3.1" install: - ".travis/install.sh" diff --git a/.travis/install.sh b/.travis/install.sh index d446b38a..d7423ce7 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -3,45 +3,6 @@ set -e set -x -if [[ "$NGHTTP2" = true ]]; then - # GCC 4.6 seems to cause problems, so go straight to 4.8. - sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test - sudo apt-get update - sudo apt-get install g++-4.8 libstdc++-4.8-dev - export CXX="g++-4.8" CC="gcc-4.8" - $CC --version - - # Install nghttp2. Right now I haven't built a PPA for this so we have to - # do it from source, which kinda sucks. First, install a ton of - # prerequisite packages. - sudo apt-get install autoconf automake autotools-dev libtool pkg-config \ - zlib1g-dev libcunit1-dev libssl-dev libxml2-dev \ - libevent-dev libjansson-dev libjemalloc-dev - pip install cython - - # Now, download and install nghttp2's latest version. - git clone https://github.com/tatsuhiro-t/nghttp2.git - cd nghttp2 - DIR=`pwd` - export PYTHONPATH="$DIR/lib/python${TRAVIS_PYTHON_VERSION}/site-packages" - mkdir -p $PYTHONPATH - autoreconf -i - automake - autoconf - ./configure --disable-threads --prefix=`pwd` - make - make install - - # The makefile doesn't install into the active virtualenv. Install again. - cd python - python setup.py install - cd ../.. - - # Let's try ldconfig. - sudo sh -c 'echo "/usr/local/lib" > /etc/ld.so.conf.d/libnghttp2.conf' - sudo ldconfig -fi - if [[ "$HYPER_FAST_PARSE" = true ]]; then pip install pycohttpparser~=1.0 fi From cced203bf4c7c4ac81007134d2a3b4da5daae8e9 Mon Sep 17 00:00:00 2001 From: Cory Benfield Date: Wed, 7 Dec 2016 10:20:20 +0000 Subject: [PATCH 2/3] Don't pass tests if coverage succeeds but tests fail. --- .travis.yml | 12 +----------- .travis/run.sh | 15 +++++++++++++++ 2 files changed, 16 insertions(+), 11 deletions(-) create mode 100644 .travis/run.sh diff --git a/.travis.yml b/.travis.yml index 92512b96..18b52dbf 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,14 +22,4 @@ install: before_script: "flake8 --max-complexity 15 --exclude 'hyper/packages/*' hyper test" script: - - > - if [[ "$TEST_RELEASE" == true ]]; then - py.test test_release.py - else - if [[ $TRAVIS_PYTHON_VERSION == pypy ]]; then - py.test test/ - else - coverage run -m py.test test/ - coverage report - fi - fi + - ".travis/run.sh" diff --git a/.travis/run.sh b/.travis/run.sh new file mode 100644 index 00000000..43d9dd65 --- /dev/null +++ b/.travis/run.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +set -e +set -x + +if [[ "$TEST_RELEASE" == true ]]; then + py.test test_release.py +else + if [[ $TRAVIS_PYTHON_VERSION == pypy ]]; then + py.test test/ + else + coverage run -m py.test test/ + coverage report + fi +fi From 654d4a4e632829646b70d17fe5d43cd8871be9ba Mon Sep 17 00:00:00 2001 From: Cory Benfield Date: Wed, 7 Dec 2016 10:27:20 +0000 Subject: [PATCH 3/3] Installable is good. --- .travis/run.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 .travis/run.sh diff --git a/.travis/run.sh b/.travis/run.sh old mode 100644 new mode 100755