From 29cc8cd8289aa54e9c4aee2921a1822d44239965 Mon Sep 17 00:00:00 2001 From: sadams Date: Mon, 23 Sep 2019 13:58:22 -0500 Subject: [PATCH 1/2] added pycodestyle checking and ci structure --- .ci/integration.sh | 23 +++++++++++++++++++++++ .travis.yml | 2 +- integration.sh | 10 ---------- tox.ini | 2 ++ 4 files changed, 26 insertions(+), 11 deletions(-) create mode 100755 .ci/integration.sh delete mode 100755 integration.sh create mode 100644 tox.ini diff --git a/.ci/integration.sh b/.ci/integration.sh new file mode 100755 index 0000000..3bb530a --- /dev/null +++ b/.ci/integration.sh @@ -0,0 +1,23 @@ +#!/bin/bash + +# failure is a natural part of life +set -e + +# build the package +python setup.py install + +echo "Checking code for style problems..." + + pycodestyle \ + --show-pep8 \ + --show-source \ + --verbose \ + $(pwd) + +echo "Done checking code for style problems." + +echo "Running integration tests ..." + +python -m pytest + +echo "Done runnning integration tests." diff --git a/.travis.yml b/.travis.yml index 270cc07..24e4d0c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,6 @@ script: # Install libraries only needed by tests - pip install requests # Run tests - - python -m pytest + - sh .ci/integration.sh after_success: - echo "tests passed" diff --git a/integration.sh b/integration.sh deleted file mode 100755 index 4cfa826..0000000 --- a/integration.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash - -# failure is a natural part of life -set -e - -# build the package -python setup.py install - -# run tests -python -m pytest diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000..c178190 --- /dev/null +++ b/tox.ini @@ -0,0 +1,2 @@ +[pycodestyle] +ignore = E501 From ae4b3cde6a151715a35fa546863058b31d3b1cef Mon Sep 17 00:00:00 2001 From: adamsxs Date: Mon, 23 Sep 2019 15:45:52 -0500 Subject: [PATCH 2/2] added pycodestyle to pip dependencies --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 24e4d0c..26d2655 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,6 +11,7 @@ install: script: # Install libraries only needed by tests - pip install requests + - pip install pycodestyle # Run tests - sh .ci/integration.sh after_success: