mirror of
https://github.com/django/django.git
synced 2025-07-04 17:59:13 +00:00
[3.2.x] Fixed #33082 -- Fixed CommandTests.test_subparser_invalid_option on Python 3.9.7+.
Thanks Michał Górny for the report. Backport of 50ed545e2fa02c51e0d1559b83624f256e4b499b from main.
This commit is contained in:
parent
707239eabf
commit
b61f44c339
@ -334,7 +334,7 @@ class CommandTests(SimpleTestCase):
|
|||||||
self.assertIn('bar', out.getvalue())
|
self.assertIn('bar', out.getvalue())
|
||||||
|
|
||||||
def test_subparser_invalid_option(self):
|
def test_subparser_invalid_option(self):
|
||||||
msg = "Error: invalid choice: 'test' (choose from 'foo')"
|
msg = "invalid choice: 'test' (choose from 'foo')"
|
||||||
with self.assertRaisesMessage(CommandError, msg):
|
with self.assertRaisesMessage(CommandError, msg):
|
||||||
management.call_command('subparser', 'test', 12)
|
management.call_command('subparser', 'test', 12)
|
||||||
if PY37:
|
if PY37:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user