def testInvalidEventDtype(self):
    with self.assertRaisesWithPredicateMatch(TypeError, 'power.dtype .* not a supported .* type'):
        power = tf.constant(5.0, dtype=tf.float16)
        zipf = tfd.Zipf(power=power, dtype=tf.int32, validate_args=True)
        self.evaluate(zipf.sample())
def testInvalidEventDtype(self):
    with self.assertRaisesWithPredicateMatch(TypeError, 'power.dtype .* not a supported .* type'):
        power = tf.constant(5.0, dtype=tf.float16)
        zipf = tfd.Zipf(power=power, dtype=tf.int32, validate_args=True)
        self.evaluate(zipf.sample())