Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
763edc1c
Commit
763edc1c
authored
Mar 08, 2013
by
Victor Stinner
Browse files
Options
Browse Files
Download
Plain Diff
(Merge 3.3) Issue #17223: the test is specific to 32-bit wchar_t type
Skip the test on Windows.
parents
857b24b0
29c0034f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
11 deletions
+3
-11
Lib/test/test_array.py
Lib/test/test_array.py
+3
-11
No files found.
Lib/test/test_array.py
View file @
763edc1c
...
...
@@ -24,15 +24,7 @@ try:
except
struct
.
error
:
have_long_long
=
False
try
:
import
ctypes
sizeof_wchar
=
ctypes
.
sizeof
(
ctypes
.
c_wchar
)
except
ImportError
:
import
sys
if
sys
.
platform
==
'win32'
:
sizeof_wchar
=
2
else
:
sizeof_wchar
=
4
sizeof_wchar
=
array
.
array
(
'u'
).
itemsize
class
ArraySubclass
(
array
.
array
):
...
...
@@ -1076,8 +1068,8 @@ class UnicodeTest(StringTest, unittest.TestCase):
# U+FFFFFFFF is an invalid code point in Unicode 6.0
invalid_str
=
b'
\
xff
\
xff
\
xff
\
xff
'
else
:
#
invalid UTF-16 surrogate pair
invalid_str
=
b'
\
xff
\
xdf
\
x61
\
x00
'
#
PyUnicode_FromUnicode() cannot fail with 16-bit wchar_t
self
.
skipTest
(
"specific to 32-bit wchar_t"
)
a
=
array
.
array
(
'u'
,
invalid_str
)
self
.
assertRaises
(
ValueError
,
a
.
tounicode
)
self
.
assertRaises
(
ValueError
,
str
,
a
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment