-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set up Travis CI like in the main repo (vfaronov/httpolice)
- Loading branch information
Showing
14 changed files
with
171 additions
and
16 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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[report] | ||
|
||
exclude_lines = | ||
pragma: no cover | ||
def __repr__ | ||
raise NotImplementedError | ||
if __name__ == '__main__': |
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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
language: python | ||
|
||
python: "2.7" | ||
|
||
env: | ||
- REQUIRES=minimum | ||
- REQUIRES=normal | ||
|
||
install: | ||
- if [ "$REQUIRES" = minimum ]; then tools/minimum_requires.sh; fi | ||
- pip install -e . | ||
- pip install -r tools/requirements.txt | ||
|
||
cache: pip | ||
|
||
script: | ||
# Basic stuff. | ||
- python setup.py check --strict --restructuredtext | ||
- pylint *.py | ||
- py.test | ||
|
||
# Although the docs are processed by Read the Docs, | ||
# we still want to check that they are building OK. | ||
- sphinx-build -W doc/ doc/_build/ | ||
|
||
# Check the assorted reStructuredText documents at the top of the repo. | ||
- tools/check_rst.sh | ||
|
||
# Check that the source distribution includes everything it should, | ||
# and nothing it shouldn't (including all the files we just built). | ||
- check-manifest | ||
|
||
deploy: | ||
on: | ||
tags: true | ||
# Only release from one of the environments. | ||
python: "2.7" | ||
condition: $REQUIRES = normal | ||
provider: pypi | ||
user: vfaronov | ||
password: | ||
secure: CJxSxCcPAebJP0YtRVg30ZuWNZYb7Y6WJVTDuH9c59NDqCpE6y1UfXFyj9zunM3pXrfxgvh+pVA4r4dzrI8n4+OBcqlWFfumZjDhYLM2luruKc+IxVf3mEw3p5v+77ssCkWHhmN7Auh/nIQMYtNp2p8TmO+yJA7Yd4oRnGNMPv/dEAKQlOGAYwI6i1rn+orknI+8q2cc7bmgeEUC97lMl9yhmF55aWycH+XGBVkFUiiu3/LLKzP2NG4YMTah7wFzclbPFqK4BK24Vwid0EXzQx1lEWmRyblo9msmeotD4qSCU4hwUYz5lZP4OCWkwqAA20xouK0tg17S3yq+glf4CQzEOCuCLa3r7VfgJW8ddfZ0J8rarVln8w+V22qsCvicTzRBZgEhwhZhQkHt5lOCwRJ62XgKJ6me9r+xlMYAy5QhDfj3KHUqV+om6Plj/nS/5AHduqTwRqd/mAOSIonMf/1ATYH7+Vk1HuHZPrKTqnbSrh4sdCqgWydgcVhbcF1nynxDwuG57znn6odLmMa90p/O2OdA+J2/1T4OL4akqmkf9mSZep/3nR/0fCN5AETDqdglWAG4EjNHWOnzgMsMKOyBkwn6bX0RCeXiVu13xNxalN4Od4s+//ErFkjJ70awI5Y55O+ZzUQ7ggBqhpvkRrLhL8zbDP4H+F38txAUqtw= | ||
distributions: "sdist bdist_wheel" |
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,3 +1,22 @@ | ||
include requirements.in | ||
include setup.cfg | ||
|
||
include README.rst | ||
include LICENSE.txt | ||
include CHANGELOG.rst | ||
|
||
include test_*.py | ||
include .coveragerc | ||
include .isort.cfg | ||
include pylintrc | ||
include pytest.ini | ||
|
||
# Even though Travis only works on a Git repo, | ||
# this file is important as a reference on the build procedure. | ||
include .travis.yml | ||
|
||
graft doc | ||
prune doc/_build | ||
graft tools | ||
|
||
global-exclude *.pyc |
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
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
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
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,3 +1,2 @@ | ||
[pytest] | ||
# Require 100% test coverage of the module. Do not print a coverage report. | ||
addopts = --cov=mitmproxy_httpolice.py --cov-fail-under=100 --no-cov-on-fail --cov-report= | ||
addopts = --cov=mitmproxy_httpolice.py --cov=test_fake_mitmdump.py --cov=test_real_mitmdump.py --cov-fail-under=100 --no-cov-on-fail --cov-report= |
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
mitmproxy >= 0.15 | ||
HTTPolice >= 0.3.0.dev3 |
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
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
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
test -e setup.py || { echo 'must run from repo root' >&2; exit 1; } | ||
|
||
for fn in *.rst; do | ||
rst2html.py --halt=warning "$fn" >/dev/null | ||
done |
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/sh | ||
|
||
# Install the lowest permitted versions of requirements. | ||
# This checks that these lower bounds are up-to-date. | ||
|
||
set -e | ||
|
||
test -e setup.py || { echo 'must run from repo root' >&2; exit 1; } | ||
|
||
sed -e 's/>=/==/g' <requirements.in >minimum_requirements.txt | ||
pip install -r minimum_requirements.txt |
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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
pip-tools | ||
check-manifest | ||
pylint | ||
pytest | ||
pytest-cov | ||
docutils | ||
wheel | ||
twine | ||
|
||
# mitmproxy 0.15 requires ``click >= 6.2, < 6.3``. | ||
# If we don't pin this down, we get a newer version of click and nothing works. | ||
# Eventually we will use pip-sync which will take care of this automatically. | ||
click == 6.2 | ||
|
||
# Pin down the versions of Sphinx and Alabaster as used on Read the Docs | ||
# (you can see them in the generated page footers). | ||
# This will have to be checked and synchronized from time to time. | ||
# Not sure if good idea. | ||
Sphinx == 1.3.5 | ||
alabaster == 0.7.8 |
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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# | ||
# This file is autogenerated by pip-compile | ||
# To update, run: | ||
# | ||
# pip-compile --output-file tools/requirements.txt tools/requirements.in | ||
# | ||
alabaster==0.7.8 | ||
args==0.1.0 # via clint | ||
astroid==1.4.8 # via pylint | ||
babel==2.3.4 # via sphinx | ||
backports.functools-lru-cache==1.2.1 # via pylint | ||
check-manifest==0.31 | ||
click==6.2 | ||
clint==0.5.1 # via twine | ||
configparser==3.5.0 # via pylint | ||
coverage==4.2 # via pytest-cov | ||
docutils==0.12 | ||
first==2.0.1 # via pip-tools | ||
isort==4.2.5 # via pylint | ||
Jinja2==2.8 # via sphinx | ||
lazy-object-proxy==1.2.2 # via astroid | ||
MarkupSafe==0.23 # via jinja2 | ||
mccabe==0.5.2 # via pylint | ||
pip-tools==1.7.0 | ||
pkginfo==1.3.2 # via twine | ||
py==1.4.31 # via pytest | ||
Pygments==2.1.3 # via sphinx | ||
pylint==1.6.4 | ||
pytest-cov==2.3.0 | ||
pytest==2.9.2 | ||
pytz==2016.6.1 # via babel | ||
requests-toolbelt==0.7.0 # via twine | ||
requests==2.10.0 # via requests-toolbelt, twine | ||
six==1.10.0 # via astroid, pip-tools, pylint, sphinx | ||
snowballstemmer==1.2.1 # via sphinx | ||
sphinx-rtd-theme==0.1.9 # via sphinx | ||
Sphinx==1.3.5 # via sphinx-rtd-theme | ||
twine==1.7.4 | ||
wheel==0.29.0 | ||
wrapt==1.10.8 # via astroid | ||
|
||
# The following packages are commented out because they are | ||
# considered to be unsafe in a requirements file: | ||
# setuptools # via twine |