(
config: Config, op: str, left: Any, right: Any
)
| 216 | |
| 217 | |
| 218 | def pytest_assertrepr_compare( |
| 219 | config: Config, op: str, left: Any, right: Any |
| 220 | ) -> list[str] | None: |
| 221 | if config.pluginmanager.has_plugin("terminalreporter"): |
| 222 | highlighter = config.get_terminal_writer()._highlight |
| 223 | else: |
| 224 | # Keep it plaintext when not using terminalrepoterer (#14377). |
| 225 | highlighter = util.dummy_highlighter |
| 226 | explanation = list( |
| 227 | util.assertrepr_compare( |
| 228 | op=op, |
| 229 | left=left, |
| 230 | right=right, |
| 231 | verbose=config.get_verbosity(Config.VERBOSITY_ASSERTIONS), |
| 232 | highlighter=highlighter, |
| 233 | assertion_text_diff_style=util.get_assertion_text_diff_style(config), |
| 234 | ) |
| 235 | ) |
| 236 | return explanation or None |
nothing calls this directly
no test coverage detected