def testWriteWrongValue8Constraint(self):
    value8 = self.VALUE8_WRONG_CONSTRAINT
    unionConstraints = self.api.UnionConstraints()
    unionConstraints.setValue8(value8)
    writer = zserio.BitStreamWriter()
    with self.assertRaises(zserio.PythonRuntimeException):
        unionConstraints.write(writer)
def testWriteWrongValue8Constraint(self):
    value8 = self.VALUE8_WRONG_CONSTRAINT
    unionConstraints = self.api.UnionConstraints()
    unionConstraints.setValue8(value8)
    writer = zserio.BitStreamWriter()
    with self.assertRaises(zserio.PythonRuntimeException):
        unionConstraints.write(writer)