(config: Config)
| 48 | |
| 49 | |
| 50 | def get_assertion_text_diff_style(config: Config) -> _AssertionTextDiffStyle: |
| 51 | style = str(config.getini(ASSERTION_TEXT_DIFF_STYLE_INI)) |
| 52 | match style: |
| 53 | case "ndiff" | "block": |
| 54 | return style |
| 55 | case _: |
| 56 | choices = ", ".join( |
| 57 | repr(choice) for choice in ASSERTION_TEXT_DIFF_STYLE_CHOICES |
| 58 | ) |
| 59 | raise UsageError( |
| 60 | f"{ASSERTION_TEXT_DIFF_STYLE_INI} must be one of {choices}; got {style!r}" |
| 61 | ) |
| 62 | |
| 63 | |
| 64 | def validate_assertion_text_diff_style(config: Config) -> None: |
no test coverage detected