MCPcopy Index your code
hub / github.com/python/cpython / test_help_non_breaking_spaces

Method test_help_non_breaking_spaces

Lib/test/test_argparse.py:2839–2855  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2837 '''))
2838
2839 def test_help_non_breaking_spaces(self):
2840 parser = ErrorRaisingArgumentParser(
2841 prog='PROG', description='main description')
2842 parser.add_argument(
2843 "--non-breaking", action='store_false',
2844 help='help message containing non-breaking spaces shall not '
2845 'wrap\N{NO-BREAK SPACE}at non-breaking spaces')
2846 self.assertEqual(parser.format_help(), textwrap.dedent('''\
2847 usage: PROG [-h] [--non-breaking]
2848
2849 main description
2850
2851 options:
2852 -h, --help show this help message and exit
2853 --non-breaking help message containing non-breaking spaces shall not
2854 wrap\N{NO-BREAK SPACE}at non-breaking spaces
2855 '''))
2856
2857 def test_help_blank(self):
2858 # Issue 24444

Callers

nothing calls this directly

Calls 5

add_argumentMethod · 0.45
assertEqualMethod · 0.45
format_helpMethod · 0.45
dedentMethod · 0.45

Tested by

no test coverage detected