MCPcopy Index your code
hub / github.com/RustPython/RustPython / do_test_standalone_uuid

Method do_test_standalone_uuid

Lib/test/test_uuid.py:1147–1154  ·  view source on GitHub ↗
(self, version)

Source from the content-addressed store, hash-verified

1145 uuid = None # to be defined in subclasses
1146
1147 def do_test_standalone_uuid(self, version):
1148 stdout = io.StringIO()
1149 with contextlib.redirect_stdout(stdout):
1150 self.uuid.main()
1151 output = stdout.getvalue().strip()
1152 u = self.uuid.UUID(output)
1153 self.assertEqual(output, str(u))
1154 self.assertEqual(u.version, version)
1155
1156 @mock.patch.object(sys, "argv", ["", "-u", "uuid1"])
1157 def test_cli_uuid1(self):

Callers 4

test_cli_uuid1Method · 0.95
test_cli_uuid6Method · 0.95
test_cli_uuid7Method · 0.95
test_cli_uuid8Method · 0.95

Calls 5

getvalueMethod · 0.95
strFunction · 0.85
mainMethod · 0.45
stripMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected