Skip to content

Instantly share code, notes, and snippets.

@Knio
Last active August 29, 2015 13:57
Show Gist options
  • Save Knio/9767214 to your computer and use it in GitHub Desktop.
Save Knio/9767214 to your computer and use it in GitHub Desktop.
Script started on Tue 25 Mar 2014 10:37:50 AM PDT
tom@zkpq:~$ cat test.py
def test1():
assert 'Hi\nThere' == \
'''Hi
There'''
tom@zkpq:~$ unix2dos test.py
unix2dos: converting file test.py to DOS format ...
tom@zkpq:~$ python -m pytest test.py
========================================================= test session starts =========================================================
platform linux2 -- Python 2.7.3 -- py-1.4.20 -- pytest-2.5.2

collecting 0 items
collecting 1 items
collected 1 items

test.py .
====================================================== 1 passed in 0.02 seconds =======================================================
tom@zkpq:~$ ./bin/pypy/bin/pypy -m pytest test.py
========================================================= test session starts =========================================================
platform linux2 -- Python 2.7.3[pypy-2.2.1-final] -- py-1.4.20 -- pytest-2.5.2

collecting 0 items
collecting 1 items
collected 1 items

test.py F
============================================================== FAILURES ===============================================================
________________________________________________________________ test1 ________________________________________________________________
 def test1():
> assert 'Hi\nThere' == \
 '''Hi
 There'''
E assert 'Hi\nThere' == 'Hi\r\nThere'
E - Hi
E + Hi\r
E There
test.py:2: AssertionError
====================================================== 1 failed in 0.05 seconds =======================================================
tom@zkpq:~$ ./bin/pypy/bin/pypy -m pytest test.py --assert plain
========================================================= test session starts =========================================================
platform linux2 -- Python 2.7.3[pypy-2.2.1-final] -- py-1.4.20 -- pytest-2.5.2

collecting 0 items
collecting 1 items
collected 1 items

test.py .
====================================================== 1 passed in 0.02 seconds =======================================================
Script done on Tue 25 Mar 2014 10:39:09 AM PDT
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment