Skip to content

Commit

Permalink
added general pytest fixes
Browse files Browse the repository at this point in the history
clarified README to mention the pytest-timeout dependency

added comments to the travis-clean-path.sh
  • Loading branch information
Odegard, Ken (Flamingo Technologies) committed Aug 8, 2016
1 parent d9980ed commit 0b00fbc
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ install:
- source ./utils/travis-run-install.sh
- echo "DONE INSTALLING"

# CSH has issues when variables get too long
# A common error that may occur would be a "Word too long" error and is probably related to the PATH variable
# Here we use "travis-clean-path.sh" to remove duplicates from the path variable before trying to run the tests
script:
- echo "START RUNNING"
- which -a python
Expand Down
6 changes: 3 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,6 @@ separate instance of `Miniconda <http://conda.pydata.org/miniconda.html>`_ and
work off it. This is also the only way to test conda in both Python 2 and
Python 3, as conda can only be installed into a root environment.

Run the conda tests by ``conda install pytest pytest-cov`` and then running ``py.test``
in the conda directory. The tests are also run by Travis CI when you make a
pull request.
Run the conda tests by ``conda install pytest pytest-cov pytest-timeout`` and then
running ``py.test`` in the conda directory. The tests are also run by Travis CI when
you make a pull request.
3 changes: 3 additions & 0 deletions conda/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,10 @@ def human_bytes(n):
source="call",
test_echo_extra="",
nul='1>NUL 2>&1',
setvar='set {variable}="{value}"',
unsetvar='set {variable}=',
setenvvar='set {variable}="{value}"',
unsetenvvar='set {variable}=',
shell_suffix=".bat",
env_script_suffix=".bat",
printps1="@echo %PROMPT%",
Expand Down
2 changes: 2 additions & 0 deletions utils/travis-clean-path.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
export BACKUP_PATH="$PATH"

# http://unix.stackexchange.com/questions/40749/remove-duplicate-path-entries-with-awk-command
# TO-DO: consider adding more path cleanup like symlinking paths that are longer than __
if [ -n "$PATH" ]; then
old_PATH="$PATH:"
PATH=""
Expand Down

0 comments on commit 0b00fbc

Please sign in to comment.