diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2017-02-02 13:18:43 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2017-02-02 13:18:43 (GMT) |
commit | 64e91275e37d881832b7c0cacd1b45c4c4ef4ba4 (patch) | |
tree | 7b62e115b36325974fb0391b9dc44f394ac5910b /Lib/test/test_struct.py | |
parent | 23dcccb75bf5484399feeb5d03bf21a4e4c1c4c2 (diff) | |
parent | a5917d1d1584bb9f7affec5a5d66bb2d24d7623e (diff) | |
download | cpython-64e91275e37d881832b7c0cacd1b45c4c4ef4ba4.zip cpython-64e91275e37d881832b7c0cacd1b45c4c4ef4ba4.tar.gz cpython-64e91275e37d881832b7c0cacd1b45c4c4ef4ba4.tar.bz2 |
Merge 3.5
Diffstat (limited to 'Lib/test/test_struct.py')
-rw-r--r-- | Lib/test/test_struct.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/test_struct.py b/Lib/test/test_struct.py index 4d9d601..be00475 100644 --- a/Lib/test/test_struct.py +++ b/Lib/test/test_struct.py @@ -412,6 +412,10 @@ class StructTest(unittest.TestCase): for i in range(6, len(test_string) + 1): self.assertRaises(struct.error, struct.unpack_from, fmt, data, i) + # keyword arguments + self.assertEqual(s.unpack_from(buffer=test_string, offset=2), + (b'cd01',)) + def test_pack_into(self): test_string = b'Reykjavik rocks, eow!' writable_buf = array.array('b', b' '*100) |