Author: Brian Kearns <bdkea...@gmail.com> Branch: Changeset: r62016:cfa3750d858f Date: 2013-03-04 15:26 -0500 http://bitbucket.org/pypy/pypy/changeset/cfa3750d858f/
Log: clean up pyrepl test skips diff --git a/pypy/module/test_lib_pypy/pyrepl/test_basic.py b/pypy/module/test_lib_pypy/pyrepl/test_basic.py --- a/pypy/module/test_lib_pypy/pyrepl/test_basic.py +++ b/pypy/module/test_lib_pypy/pyrepl/test_basic.py @@ -16,7 +16,6 @@ # RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF # CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN # CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -import os import pytest from .infrastructure import read_spec diff --git a/pypy/module/test_lib_pypy/pyrepl/test_bugs.py b/pypy/module/test_lib_pypy/pyrepl/test_bugs.py --- a/pypy/module/test_lib_pypy/pyrepl/test_bugs.py +++ b/pypy/module/test_lib_pypy/pyrepl/test_bugs.py @@ -25,9 +25,6 @@ import pytest -import os -if os.name == 'nt': - pytest.skip('pyrepl does not work properly on windows') class HistoricalTestReader(HistoricalReader, BaseTestReader): pass @@ -48,6 +45,7 @@ ] read_spec(spec, HistoricalTestReader) +@pytest.mark.skipif("os.name != 'posix'") def test_signal_failure(monkeypatch): import os import pty diff --git a/pypy/module/test_lib_pypy/pyrepl/test_readline.py b/pypy/module/test_lib_pypy/pyrepl/test_readline.py --- a/pypy/module/test_lib_pypy/pyrepl/test_readline.py +++ b/pypy/module/test_lib_pypy/pyrepl/test_readline.py @@ -1,15 +1,16 @@ import os -import pytest -if os.name == 'nt': - pytest.skip('No pyrepl.readline in windows, requires termios') - -from pyrepl.readline import _ReadlineWrapper - -import pty +if os.name == 'posix': + from pyrepl.readline import _ReadlineWrapper +else: + import pytest + e = pytest.raises(ImportError, "import pyrepl.readline") + assert 'termios' in e.value.message + pytest.skip('pyrepl.readline requires termios') def test_raw_input(): + import pty master, slave = pty.openpty() readline_wrapper = _ReadlineWrapper(slave, slave) os.write(master, b'input\n') _______________________________________________ pypy-commit mailing list pypy-commit@python.org http://mail.python.org/mailman/listinfo/pypy-commit