MCPcopy Index your code
hub / github.com/python/cpython / assertBadNetmask

Method assertBadNetmask

Lib/test/test_ipaddress.py:796–799  ·  view source on GitHub ↗
(addr, netmask)

Source from the content-addressed store, hash-verified

794
795 def test_netmask_errors(self):
796 def assertBadNetmask(addr, netmask):
797 msg = "%r is not a valid netmask" % netmask
798 with self.assertNetmaskError(re.escape(msg)):
799 self.factory("%s/%s" % (addr, netmask))
800
801 assertBadNetmask("::1", "")
802 assertBadNetmask("::1", "::1")

Callers

nothing calls this directly

Calls 3

assertNetmaskErrorMethod · 0.80
escapeMethod · 0.80
factoryMethod · 0.45

Tested by

no test coverage detected