def test_ipv4_parses_zero(self): self.assertEquals(ipv4_from_user('192.0.1.42'), '192.0.1.42')
def _from_request_impl(self, value): return ipv4_from_user(value, on_error=self._illegal_element)
def test_ipv4_parses(self): self.assertEquals(ipv4_from_user('192.168.1.42'), '192.168.1.42')
def from_argument(self, value): return ipv4_from_user(value, on_error=self._illegal_argument)
def test_ipv4_parses_zero(self): self.assertEquals(ipv4_from_user("192.0.1.42"), "192.0.1.42")
def test_ipv4_parses(self): self.assertEquals(ipv4_from_user("192.168.1.42"), "192.168.1.42")