

def test_read_bad_value(self):
    '\n        Test that a ValueError is raised when the Boolean read operations\n        reads a valid integer but invalid Boolean.\n        '
    encoding = b'B\x00\x00\x06\x00\x00\x00\x08\x00\x00\x00\x00\x00\x00\x00\x02'
    stream = utils.BytearrayStream(encoding)
    boolean = primitives.Boolean()
    self.assertRaises(ValueError, boolean.read, stream)

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