[2.2.x] Fixed #33082 -- Fixed CommandTests.test_subparser_invalid_option on Python 3.9.7+.

Thanks Michał Górny for the report.

Backport of 50ed545e2f from main.
This commit is contained in:
Mariusz Felisiak 2021-09-02 10:56:56 +02:00
parent a9c0aa11e7
commit 05bc1c81aa
1 changed files with 1 additions and 1 deletions

View File

@ -218,7 +218,7 @@ class CommandTests(SimpleTestCase):
self.assertIn('bar', out.getvalue())
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):
management.call_command('subparser', 'test', 12)