diff options
author | INADA Naoki <inada-n@klab.com> | 2012-12-29 01:43:16 +0900 |
---|---|---|
committer | INADA Naoki <inada-n@klab.com> | 2012-12-29 01:43:16 +0900 |
commit | d57e369258a388ee64ad900ee7e975da25ca36ec (patch) | |
tree | 32988fcd362d9cac3a6c31c9f16d94d0dac6d732 /test/test_except.py | |
parent | 7b11a42825a631ba85608a3c0943919073d9899e (diff) | |
parent | 72416e403c6d70b6fbc4ea8e05e1fe7f02a6561a (diff) | |
download | msgpack-python-d57e369258a388ee64ad900ee7e975da25ca36ec.tar.gz |
Fix unpacker doesn't raise exception for invalid input (Merge branch '0.2'
Fixes #40
Conflicts:
ChangeLog.rst
msgpack/_unpacker.pyx
msgpack/_version.py
Diffstat (limited to 'test/test_except.py')
-rw-r--r-- | test/test_except.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/test_except.py b/test/test_except.py index e142dd6..35287df 100644 --- a/test/test_except.py +++ b/test/test_except.py @@ -6,6 +6,7 @@ from msgpack import packb, unpackb import datetime + class DummyException(Exception): pass @@ -28,6 +29,11 @@ def test_raise_from_object_hook(): object_pairs_hook=hook) +@raises(ValueError) +def test_invalidvalue(): + unpackb(b'\xd9\x97#DL_') + + if __name__ == '__main__': from nose import main main() |