File tree Expand file tree Collapse file tree 3 files changed +5
-9
lines changed Expand file tree Collapse file tree 3 files changed +5
-9
lines changed Original file line number Diff line number Diff line change 2020 include :
2121 # OSX tests - first (in test stage), since they are the slower ones.
2222 - &test-macos
23- # NOTE: (tests with) pexpect appear to be buggy on Travis,
24- # at least with coverage.
25- # Log: https://travis-ci.org/pytest-dev/pytest/jobs/500358864
2623 os : osx
2724 osx_image : xcode10.1
2825 language : generic
3330 - python -V
3431 - test $(python -c 'import sys; print("%d%d" % sys.version_info[0:2])') = 27
3532 - << : *test-macos
36- env : TOXENV=py37-xdist
33+ env : TOXENV=py37-pexpect,py37- xdist PYTEST_COVERAGE=1
3734 before_install :
3835 - which python3
3936 - python3 -V
Original file line number Diff line number Diff line change 44from __future__ import print_function
55
66import os
7- import platform
87import sys
98
109import six
@@ -153,10 +152,11 @@ def test_func():
153152
154153 @staticmethod
155154 def flush (child ):
156- if platform .system () == "Darwin" :
157- return
158155 if child .isalive ():
156+ # Read if the test has not (e.g. test_pdb_unittest_skip).
157+ child .read ()
159158 child .wait ()
159+ assert not child .isalive ()
160160
161161 def test_pdb_unittest_postmortem (self , testdir ):
162162 p1 = testdir .makepyfile (
@@ -797,7 +797,6 @@ def test_post_mortem():
797797 rest = child .read ().decode ("utf8" )
798798 assert "leave_pdb_hook" in rest
799799 assert "1 failed" in rest
800- child .sendeof ()
801800 self .flush (child )
802801
803802 def test_pdb_custom_cls (self , testdir , custom_pdb_calls ):
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ setenv =
4040 lsof: _PYTEST_TOX_POSARGS_LSOF =--lsof
4141
4242 pexpect: _PYTEST_TOX_PLATFORM =linux|darwin
43- pexpect: _PYTEST_TOX_POSARGS_PEXPECT =testing/test_pdb.py testing/test_terminal.py testing/test_unittest.py
43+ pexpect: _PYTEST_TOX_POSARGS_PEXPECT =-m uses_pexpect
4444
4545 twisted: _PYTEST_TOX_POSARGS_TWISTED =testing/test_unittest.py
4646
You can’t perform that action at this time.
0 commit comments