summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_argparse.py
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2021-11-12 18:44:25 (GMT)
committerGitHub <noreply@github.com>2021-11-12 18:44:25 (GMT)
commit587ff7f50bcbfd8346c6d5db459a1628a350c04d (patch)
tree6719e39328cb8ce3d490ca6532797bb64ebf14fb /Lib/test/test_argparse.py
parent8b6a474071bcc88ec3453e16f079181e551513c3 (diff)
downloadcpython-587ff7f50bcbfd8346c6d5db459a1628a350c04d.zip
cpython-587ff7f50bcbfd8346c6d5db459a1628a350c04d.tar.gz
cpython-587ff7f50bcbfd8346c6d5db459a1628a350c04d.tar.bz2
bpo-45235: Revert an argparse bugfix that caused a regression (GH-29525) (GH-29531)
Diffstat (limited to 'Lib/test/test_argparse.py')
-rw-r--r--Lib/test/test_argparse.py6
1 files changed, 0 insertions, 6 deletions
diff --git a/Lib/test/test_argparse.py b/Lib/test/test_argparse.py
index c3c3a75..d79ac5a 100644
--- a/Lib/test/test_argparse.py
+++ b/Lib/test/test_argparse.py
@@ -3095,12 +3095,6 @@ class TestSetDefaults(TestCase):
xparser.set_defaults(foo=2)
self.assertEqual(NS(foo=2), parser.parse_args(['X']))
- def test_set_defaults_on_subparser_with_namespace(self):
- parser = argparse.ArgumentParser()
- xparser = parser.add_subparsers().add_parser('X')
- xparser.set_defaults(foo=1)
- self.assertEqual(NS(foo=2), parser.parse_args(['X'], NS(foo=2)))
-
def test_set_defaults_same_as_add_argument(self):
parser = ErrorRaisingArgumentParser()
parser.set_defaults(w='W', x='X', y='Y', z='Z')