fix: 停止后不再多发心跳,换课按知识编号重置

This commit is contained in:
2026-11-16 12:02:10 +08:00
parent 019e75a95e
commit 8504ff5e85
4 changed files with 182 additions and 109 deletions
+1 -3
View File
@@ -159,7 +159,7 @@ def test_worker_view_freezes_total_after_first_beat() -> None:
_clear_user_status("u-total")
view = WorkerView("u-total", 1)
view.update(course="甲", progress=38)
view.update(course="甲", knowledge_id="k-jia", progress=38)
view.after_beat(39, ok=True)
first = autostudy_status()["users"]["u-total"]["workers"][0]["total"]
assert first == 62
@@ -933,8 +933,6 @@ def test_completed_course_skips_the_play_page(monkeypatch) -> None:
f"/kng/view/video/{COMPACT_KID}.html",
"已完成",
"视频",
{},
False,
watcher,
"",
"",