def test_ip4_anonymization(self):
     self.assertEqual(anonymize_ip_address('127.0.0.1'), '127.0.0.0')
     self.assertEqual(anonymize_ip_address('80.90.100.110'), '80.90.100.0')
 def test_ip6_anonymization(self):
     self.assertEqual(anonymize_ip_address('::1'), '::1')
     self.assertEqual(anonymize_ip_address('fe80:0:0:0:200:f8ff:f221:67af'), 'fe80:0000:0000:0000:0000:0000:0000:0000')
     self.assertEqual(anonymize_ip_address('fe80::67af'), 'fe80:0000:0000:0000:0000:0000:0000:0000')
     self.assertEqual(anonymize_ip_address('fe80:abcd:1234:02:23::67af'), 'fe80:abcd:1234:0002:0000:0000:0000:0000')