def METHOD_NAME(self):
    type_ = "_test-srvc-type._tcp.local."
    name = "xxxyyy"
    registration_name = f"{name}.{type_}"
    bad = (b'127.0.0.1', b'::1')
    for addr in bad:
        self.assertRaisesRegex(
            TypeError,
            'Addresses must either ',
            ServiceInfo,
            type_,
            registration_name,
            port=80,
            addresses=[addr],
        )