Skip to content

Commit a1ff7c7

Browse files
committed
nits
1 parent db1dcc9 commit a1ff7c7

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

tests/unit/messages/formats/adaptive_cards/test_adaptive_cards.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class TestAdaptiveCards(BaseTestFormat[dict]):
4343
def format(self, message_body: MessageBody) -> dict:
4444
return format_adaptive_card(message_body)
4545

46-
def get_expected_file_path(self, name: str) -> str:
46+
def get_expected_file_path(self, name: str) -> Path:
4747
return get_expected_file_path(FIXTURES_DIR, f"{name}.json")
4848

4949
def assert_expected_value(self, result: dict, expected_file_path: Path) -> None:

tests/unit/messages/utils.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ def get_expected_file_path(fixture_dir: Path, filename: str) -> Path:
1818
path = fixture_dir / filename
1919
if not path.exists():
2020
path.parent.mkdir(parents=True, exist_ok=True)
21-
path.write_text(json.dumps({}))
21+
if filename.endswith(".json"):
22+
path.write_text(json.dumps({}))
23+
else:
24+
path.write_text("")
2225
return path
2326

2427

0 commit comments

Comments
 (0)