Skip to content

Commit 02d0016

Browse files
committed
Update tests
1 parent 72d9344 commit 02d0016

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed

tests/unit/test_files_checks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ def test_check_jsonl_missing_field_in_conversation(tmp_path: Path):
334334
{
335335
"messages": [
336336
{"role": "user", "content": "Hi"},
337-
{"role": "assistant"},
337+
{"content": "Hello"},
338338
]
339339
}
340340
]
@@ -343,7 +343,7 @@ def test_check_jsonl_missing_field_in_conversation(tmp_path: Path):
343343

344344
report = check_file(file)
345345
assert not report["is_check_passed"]
346-
assert "Missing required column `content`" in report["message"]
346+
assert "Missing required column `role`" in report["message"]
347347

348348

349349
def test_check_jsonl_wrong_turn_type(tmp_path: Path):

tests/unit/test_preference_openai.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -149,12 +149,6 @@ def test_check_jsonl_invalid_preference_openai_missing_fields(tmp_path: Path, fi
149149
"Wrong format for non_preferred_output",
150150
id="wrong_output_format_non_preferred",
151151
),
152-
pytest.param(
153-
"missing_content",
154-
lambda item: item.update({"input": {"messages": [{"role": "user"}]}}), # type: ignore
155-
"Missing content in messages",
156-
id="missing_content",
157-
),
158152
pytest.param(
159153
"multiple_preferred_outputs",
160154
lambda item: item.update( # type: ignore

0 commit comments

Comments
 (0)