Skip to content

Commit

Permalink
Testing: Make test_calltip to time out to avoid long waiting times in…
Browse files Browse the repository at this point in the history
… Appveyor

Also make our tests to restart in case that happens
  • Loading branch information
ccordoba12 committed Jun 21, 2017
1 parent 4237eaf commit b155ef0
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 3 deletions.
4 changes: 2 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ environment:
rope pyflakes sphinx pygments pylint pycodestyle psutil nbconvert
qtawesome pickleshare qtpy pyzmq chardet mock pandas pytest
pytest-cov numpydoc scipy pillow qtconsole matplotlib jedi
PIP_DEPENDENCIES: "pytest-qt flaky"
PIP_DEPENDENCIES: "pytest-qt pytest-timeout flaky"

matrix:
- PYTHON_VERSION: "2.7"
Expand Down Expand Up @@ -41,4 +41,4 @@ install:
build: false

test_script:
- "%CMD_IN_ENV% python runtests.py"
- "%CMD_IN_ENV% python runtests.py" || "%CMD_IN_ENV% python runtests.py" || "%CMD_IN_ENV% python runtests.py"
2 changes: 1 addition & 1 deletion continuous_integration/travis/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ else
export CONDA_DEPENDENCIES="rope pyflakes sphinx pygments pylint psutil nbconvert \
qtawesome pickleshare qtpy pyzmq chardet mock nomkl pandas \
pytest pytest-cov numpydoc scipy cython pillow jedi pycodestyle"
export PIP_DEPENDENCIES="coveralls pytest-qt flaky"
export PIP_DEPENDENCIES="coveralls pytest-qt pytest-timeout flaky"
fi


Expand Down
1 change: 1 addition & 0 deletions requirements/test_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ mock
pytest
pytest-qt
pytest-cov
pytest-timeout
pandas
scipy
sympy
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,7 @@ def run(self):
'pytest-qt',
'pytest-cov',
'pytest-xvfb',
'pytest-timeout',
'mock',
'flaky',
'pandas',
Expand Down
1 change: 1 addition & 0 deletions spyder/app/tests/test_mainwindow.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ def test_change_types_in_varexp(main_window, qtbot):
@flaky(max_runs=3)
@pytest.mark.skipif(os.name != 'nt' or not PY2,
reason="It times out on Linux and Python 3")
@pytest.mark.timeout(timeout=60, method='thread')
@pytest.mark.use_introspection
def test_calltip(main_window, qtbot):
"""Hide the calltip in the editor when a matching ')' is found."""
Expand Down

0 comments on commit b155ef0

Please sign in to comment.