New issue 664: Assertions about expected exceptions documentation possible code 
error
https://bitbucket.org/hpk42/pytest/issue/664/assertions-about-expected-exceptions

realcr realcr:

Hi, 
I have seen the following piece of code in the documentation at 
http://pytest.org/latest/assert.html#assert-with-the-assert-statement  :

def test_recursion_depth():
    with pytest.raises(RuntimeError) as excinfo:
        def f():
            f()
        f()
    assert 'maximum recursion' in str(excinfo.value)

I assume that the assert line should be indented one more level to the right. I 
might be wrong about it though.


_______________________________________________
pytest-commit mailing list
pytest-commit@python.org
https://mail.python.org/mailman/listinfo/pytest-commit

Reply via email to