Fix test failures caused by type hint changes

- Use TYPE_CHECKING guard in recipes.py to prevent typing imports from
  appearing in module namespace (fixes test_recipes_are_documented)
- Update test_convert_help to check for function names with type hints
  in a more flexible way
This commit is contained in:
Claude 2025-12-15 19:28:45 +00:00
commit 9b83ae0325
No known key found for this signature in database
2 changed files with 9 additions and 4 deletions

View file

@ -41,9 +41,9 @@ def test_convert_help():
result = CliRunner().invoke(cli.cli, ["convert", "--help"])
assert result.exit_code == 0
for expected in (
"r.jsonsplit(value, ",
"r.parsedate(value, ",
"r.parsedatetime(value, ",
"r.jsonsplit(value:",
"r.parsedate(value:",
"r.parsedatetime(value:",
):
assert expected in result.output