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

Function skip_if_ABSTFN_contains_backslash

Lib/test/test_posixpath.py:28–36  ·  view source on GitHub ↗

On Windows, posixpath.abspath still returns paths with backslashes instead of posix forward slashes. If this is the case, several tests fail, so skip them.

(test)

Source from the content-addressed store, hash-verified

26ABSTFN = abspath(TESTFN)
27
28def skip_if_ABSTFN_contains_backslash(test):
29 """
30 On Windows, posixpath.abspath still returns paths with backslashes
31 instead of posix forward slashes. If this is the case, several tests
32 fail, so skip them.
33 """
34 found_backslash = '\\' in ABSTFN
35 msg = "ABSTFN is not a posix path - tests fail"
36 return [test, unittest.skip(msg)(test)][found_backslash]
37
38
39def _parameterize(*parameters):

Callers

nothing calls this directly

Calls 1

skipMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…