Skip to content

Commit e8991d6

Browse files
committed
Ignore DeprecationWarning in the new test
1 parent ce494b7 commit e8991d6

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎Lib/test/test_array.py‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,10 @@ def test_typecodes_documented(self):
134134
self.assertEqual(sorted(documented), sorted(array.typecodes))
135135
for typecode, minimum_size in documented.items():
136136
with self.subTest(typecode=typecode):
137-
self.assertGreaterEqual(array.array(typecode).itemsize,
138-
minimum_size)
137+
with warnings.catch_warnings():
138+
warnings.simplefilter('ignore', DeprecationWarning)
139+
self.assertGreaterEqual(array.array(typecode).itemsize,
140+
minimum_size)
139141

140142

141143
# Machine format codes.

0 commit comments

Comments
 (0)