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

Method __init__

Lib/doctest.py:493–509  ·  view source on GitHub ↗
(self, source, want, exc_msg=None, lineno=0, indent=0,
                 options=None)

Source from the content-addressed store, hash-verified

491 DocTestRunner's optionflags). By default, no options are set.
492 """
493 def __init__(self, source, want, exc_msg=None, lineno=0, indent=0,
494 options=None):
495 # Normalize inputs.
496 if not source.endswith('\n'):
497 source += '\n'
498 if want and not want.endswith('\n'):
499 want += '\n'
500 if exc_msg is not None and not exc_msg.endswith('\n'):
501 exc_msg += '\n'
502 # Store properties.
503 self.source = source
504 self.want = want
505 self.lineno = lineno
506 self.indent = indent
507 if options is None: options = {}
508 self.options = options
509 self.exc_msg = exc_msg
510
511 def __eq__(self, other):
512 if type(self) is not type(other):

Callers 4

__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45

Calls 1

endswithMethod · 0.45

Tested by

no test coverage detected