bpo-33967: Fix wrong use of assertRaises (GH-8306)
This commit is contained in:
parent
01b7d58982
commit
56d8f57b83
|
@ -2310,7 +2310,7 @@ class TestSingleDispatch(unittest.TestCase):
|
|||
def f(*args):
|
||||
pass
|
||||
msg = 'f requires at least 1 positional argument'
|
||||
with self.assertRaises(TypeError, msg=msg):
|
||||
with self.assertRaisesRegex(TypeError, msg):
|
||||
f()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
Loading…
Reference in New Issue