Skip to content

Commit

Permalink
add pytest-timeout to test runs
Browse files Browse the repository at this point in the history
This adds a default 30 second timeout on every test method so that
deadlocks or broken threads are move obvious in travis. It also passes
-v by default to make things a little more verbose on where things
fail when they are failing.
  • Loading branch information
sdague committed Feb 3, 2016
1 parent 3560131 commit efcba8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions requirements_test.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
flake8>=2.5.1
pylint>=1.5.3
coveralls>=1.1
pytest>=2.6.4
pytest>=2.8.0
pytest-cov>=2.2.0
betamax>=0.5.1
pytest-timeout>=1.0.0
betamax>=0.5.1
4 changes: 2 additions & 2 deletions script/test
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ cd "$(dirname "$0")/.."
echo "Running tests..."

if [ "$1" = "coverage" ]; then
py.test --cov --cov-report=
py.test -v --timeout=30 --cov --cov-report=
TEST_STATUS=$?
else
py.test
py.test -v --timeout=30
TEST_STATUS=$?
fi

Expand Down

0 comments on commit efcba8f

Please sign in to comment.