with captured_stdout() as stdout:
self._coverage(tracer)
stdout = stdout.getvalue()
- self.assertTrue("pprint.py" in stdout)
- self.assertTrue("case.py" in stdout) # from unittest
+ self.assertIn("pprint.py", stdout)
+ self.assertIn("case.py", stdout) # from unittest
files = os.listdir(TESTFN)
- self.assertTrue("pprint.cover" in files)
- self.assertTrue("unittest.case.cover" in files)
+ self.assertIn("pprint.cover", files)
+ self.assertIn("unittest.case.cover", files)
def test_coverage_ignore(self):
# Ignore all files, nothing should be traced nor printed
Core and Builtins
-----------------
+- Issue #19398: Extra slash no longer added to sys.path components in case of
+ empty compile-time PYTHONPATH components.
+
- Issue #28426: Fixed potential crash in PyUnicode_AsDecodedObject() in debug
build.
if (defpath[0] != SEP) {
wcscat(buf, prefix);
- wcscat(buf, separator);
+ if (prefixsz >= 2 && prefix[prefixsz - 2] != SEP &&
+ defpath[0] != (delim ? DELIM : L'\0')) { /* not empty */
+ wcscat(buf, separator);
+ }
}
if (delim) {