Add __bool__ as well as __nonzero__ for python3
This commit is contained in:
parent
a484794820
commit
9c012ed07d
@ -166,6 +166,9 @@ class MessageTest(BaseTestCase):
|
||||
def __nonzero__(self):
|
||||
raise BadArgError()
|
||||
|
||||
def __bool__(self):
|
||||
raise BadArgError()
|
||||
|
||||
with self.assertRaises(BadArgError):
|
||||
golden_message.SerializeToString(deterministic=BadArg())
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user