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

Method setUp

Lib/test/test_optparse.py:897–900  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

895
896class TestMultipleArgs(BaseTest):
897 def setUp(self):
898 self.parser = InterceptingOptionParser(usage=SUPPRESS_USAGE)
899 self.parser.add_option("-p", "--point",
900 action="store", nargs=3, type="float", dest="point")
901
902 def test_nargs_with_positional_args(self):
903 self.assertParseOK(["foo", "-p", "1", "2.5", "-4.3", "xyz"],

Callers

nothing calls this directly

Calls 2

add_optionMethod · 0.45

Tested by

no test coverage detected