

def test_write_bad_value(self):
    '\n        Test that an Exception is raised when the Boolean write operation fails\n        on a bad Boolean value.\n        '
    stream = utils.BytearrayStream()
    boolean = primitives.Boolean()
    boolean.value = 'invalid'
    self.assertRaises(Exception, boolean.write, stream)

dataset/ETHPy150Open OpenKMIP/PyKMIP/kmip/tests/unit/core/primitives/test_boolean.py TestBoolean.test_write_bad_value/original