def test_error(self): with pytest.raises(ValueError): inputs.datetime_from_rfc822('Fake, 01 XXX 2011')
def test_valid_values(self, value, expected): assert inputs.datetime_from_rfc822(value) == expected