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

Method expect_success

Lib/test/test_clinic.py:2959–2964  ·  view source on GitHub ↗
(self, *args)

Source from the content-addressed store, hash-verified

2957 return out.getvalue(), err.getvalue(), cm.exception.code
2958
2959 def expect_success(self, *args):
2960 out, err, code = self.run_clinic(*args)
2961 if code != 0:
2962 self.fail("\n".join([f"Unexpected failure: {args=}", out, err]))
2963 self.assertEqual(err, "")
2964 return out
2965
2966 def expect_failure(self, *args):
2967 out, err, code = self.run_clinic(*args)

Callers 9

test_externalMethod · 0.95
test_no_changeMethod · 0.95
test_cli_forceMethod · 0.95
test_cli_makeMethod · 0.95
test_cli_make_excludeMethod · 0.95
test_cli_verboseMethod · 0.95
test_cli_helpMethod · 0.95
test_cli_convertersMethod · 0.95
test_file_destMethod · 0.95

Calls 4

run_clinicMethod · 0.95
failMethod · 0.45
joinMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected