summaryrefslogtreecommitdiffstats
path: root/Lib/ctypes/test/test_libc.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2007-10-24 18:41:19 (GMT)
committerGuido van Rossum <guido@python.org>2007-10-24 18:41:19 (GMT)
commit97f9d4f31224e72e5c714ea7e509c4fd0044f0e2 (patch)
tree62e3de5a53ccbf0d712097671a4d152b4c1ae0be /Lib/ctypes/test/test_libc.py
parentb98cda44b714d41e466326f95adcbc649dde1c21 (diff)
downloadcpython-97f9d4f31224e72e5c714ea7e509c4fd0044f0e2.zip
cpython-97f9d4f31224e72e5c714ea7e509c4fd0044f0e2.tar.gz
cpython-97f9d4f31224e72e5c714ea7e509c4fd0044f0e2.tar.bz2
Patch #1318 by Amaury Forgeot d'Arc.
Updates to ctypes for python 3.0 to make the tests pass. Notable changes are: - return bytes instead of str8 - integers in range(256) are accepted as "one char string": libc.strchr("abcdef", 98) is now valid. - directly use the wide-char version of the win32 function LoadLibrary.
Diffstat (limited to 'Lib/ctypes/test/test_libc.py')
-rw-r--r--Lib/ctypes/test/test_libc.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/ctypes/test/test_libc.py b/Lib/ctypes/test/test_libc.py
index c39f350..0e14c2f 100644
--- a/Lib/ctypes/test/test_libc.py
+++ b/Lib/ctypes/test/test_libc.py
@@ -24,7 +24,7 @@ class LibTest(unittest.TestCase):
chars = create_string_buffer("spam, spam, and spam")
lib.my_qsort(chars, len(chars)-1, sizeof(c_char), comparefunc(sort))
- self.failUnlessEqual(chars.raw, " ,,aaaadmmmnpppsss\x00")
+ self.failUnlessEqual(chars.raw, b" ,,aaaadmmmnpppsss\x00")
if __name__ == "__main__":
unittest.main()