Source code:
def test_function(): assert f() == 4
def test_function(): > assert f() == 4 E assert 3 == 4 E + where 3 = f()
No more verbose self.assertTheItemIsInThisList(item, list) at least.
Source code:
Output: Here's how it works: http://pytest.org/latest/assert.html#assert-details -- when importing the test module, all simple asserts are rewritten (which has some limitations if side effects are involved).No more verbose self.assertTheItemIsInThisList(item, list) at least.