MCPcopy Create free account
hub / github.com/pytest-dev/pytest / format_for_fnmatch

Method format_for_fnmatch

testing/conftest.py:169–171  ·  view source on GitHub ↗

Replace color names for use with LineMatcher.fnmatch_lines

(cls, lines: List[str])

Source from the content-addressed store, hash-verified

167
168 @classmethod
169 def format_for_fnmatch(cls, lines: List[str]) -> List[str]:
170 """Replace color names for use with LineMatcher.fnmatch_lines"""
171 return [line.format(**cls.COLORS).replace("[", "[[]") for line in lines]
172
173 @classmethod
174 def format_for_rematch(cls, lines: List[str]) -> List[str]:

Calls 1

formatMethod · 0.45

Tested by

no test coverage detected