Merge pull request #5531 from deepseek-harness/fix/5520-job-session-timestamps
fix(jobs): persist owned lifecycle timing in sessions
This commit is contained in:
commit
e75e13313c
142 files changed
+3196
-752
No files matched your search
@@ -766,3 +766,20 @@ def test_live_turn_accepts_explanation_before_acknowledgement(prefix: str) -> No
|
||||
def test_live_turn_rejects_missing_standalone_acknowledgement(answer: str) -> None:
|
||||
with pytest.raises(AssertionError, match="turn returned"):
|
||||
SMOKE["assert_live_turn"]("create", live_result(final_response=answer))
|
||||
|
||||
|
||||
def test_job_snapshot_normalization_preserves_pairing_and_uncertainty():
|
||||
normalize = SMOKE["normalize_snapshot_value"]
|
||||
replacements = []
|
||||
first = {"type": "job/registered", "data": {"jobId": "job-a", "startedAt": 10}}
|
||||
last = {"type": "job/settled", "data": {"jobId": "job-a", "startedAt": 10,
|
||||
"finishedAt": 20, "producerReported": False}}
|
||||
other = {"type": "job/registered", "data": {"jobId": "job-b", "startedAt": 30}}
|
||||
a, b, c = normalize([first, last, other], replacements)
|
||||
assert a["data"] == {"jobId": "{{id:1}}", "startedAt": 0}
|
||||
assert b["data"] == {"jobId": "{{id:1}}", "startedAt": 0, "finishedAt": 0, "producerReported": False}
|
||||
assert c["data"]["jobId"] == "{{id:2}}"
|
||||
assert normalize([a, b, c], []) == [a, b, c]
|
||||
assert normalize({"type": "tool/result", "data": {"startedAt": 100, "finishedAt": 200}}, []) == {
|
||||
"type": "tool/result", "data": {"startedAt": 100, "finishedAt": 200},
|
||||
}
|
||||
Reference in new issue
Block a user