update
This commit is contained in:
@@ -31,9 +31,9 @@ async def test_nur_ohne_sieht_fehlende_flashcard():
|
||||
"""Ein lebendes Beispiel darf die Flashcard-Nachgenerierung nicht blockieren."""
|
||||
topic = topic_anlegen("fcfehlt")
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", soll_id=1, braucht=db.j([]))
|
||||
status="neu", soll_id=1)
|
||||
b = db.insert("atome", topic=topic, titel="Y", typ="begriff", definition="d",
|
||||
status="neu", soll_id=1, braucht=db.j([]))
|
||||
status="neu", soll_id=1)
|
||||
# a: nur ein Beispiel, keine Flashcard → muss nachgeneriert werden
|
||||
db.insert("artefakte", atom_id=a, typ="beispiel", status="verifiziert",
|
||||
inhalt=db.j({"text": "Beispiel"}))
|
||||
@@ -50,7 +50,7 @@ async def test_reverify_ausfall_laesst_kandidat(monkeypatch):
|
||||
topic = topic_anlegen("reverify")
|
||||
run = run_anlegen(topic)
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", braucht=db.j([]))
|
||||
status="neu")
|
||||
k = db.insert("artefakte", atom_id=a, typ="flashcard", status="kandidat",
|
||||
inhalt=db.j({"frage": "Was ist X?", "antwort": "Y", "text": ""}))
|
||||
# Fix liefert saubere Karte; Re-Verify antwortet ohne Eintrag zur id → kein Urteil
|
||||
@@ -68,7 +68,7 @@ async def test_guard_verwirft_kandidat_und_repair_kann_nachlegen():
|
||||
topic = topic_anlegen("guard")
|
||||
run = run_anlegen(topic)
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", braucht=db.j([]))
|
||||
status="neu")
|
||||
k = db.insert("artefakte", atom_id=a, typ="flashcard", status="kandidat",
|
||||
inhalt=db.j({"frage": "Was steht im Beleg?", "antwort": "x", "text": ""}))
|
||||
ctx = llm.Kontext(run, topic, "minimax")
|
||||
@@ -103,7 +103,7 @@ def test_referenziert_quelle_ignoriert_code():
|
||||
def test_formen_gate_verwirft_kaputte_tabelle():
|
||||
topic = topic_anlegen("formgate")
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", braucht=db.j([]))
|
||||
status="neu")
|
||||
gut = db.insert("artefakte", atom_id=a, typ="beispiel", status="kandidat",
|
||||
inhalt=db.j({"form": "tabelle", "tabelle": "| A | B |\n|---|---|\n| 1 | 2 |"}))
|
||||
schlecht = db.insert("artefakte", atom_id=a, typ="beispiel", status="kandidat",
|
||||
@@ -118,7 +118,7 @@ def test_beispiel_einsetzen_tabelle():
|
||||
topic = topic_anlegen("bsp-tab")
|
||||
b = db.insert("bausteine", topic=topic, ziel_id=1, titel="B", ord=0, status="neu")
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", baustein_id=b, ord=0, braucht=db.j([]))
|
||||
status="neu", baustein_id=b, ord=0)
|
||||
md = "| A | B |\n|---|---|\n| 1 | 2 |"
|
||||
art = db.insert("artefakte", atom_id=a, typ="beispiel", status="verifiziert",
|
||||
inhalt=db.j({"form": "tabelle", "tabelle": md}))
|
||||
@@ -141,7 +141,7 @@ def test_code_syntax_gate():
|
||||
def test_formen_gate_verwirft_kaputten_code():
|
||||
topic = topic_anlegen("codegate")
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", braucht=db.j([]))
|
||||
status="neu")
|
||||
gut = db.insert("artefakte", atom_id=a, typ="beispiel", status="kandidat",
|
||||
inhalt=db.j({"form": "code", "sprache": "python", "code": "print(1+1)"}))
|
||||
schlecht = db.insert("artefakte", atom_id=a, typ="beispiel", status="kandidat",
|
||||
@@ -156,7 +156,7 @@ async def test_guide_messen_toter_beispiel_marker():
|
||||
topic = topic_anlegen("bspqa")
|
||||
b = db.insert("bausteine", topic=topic, ziel_id=1, titel="B", ord=0, status="neu")
|
||||
a = db.insert("atome", topic=topic, titel="X", typ="begriff", definition="d",
|
||||
status="neu", baustein_id=b, ord=0, braucht=db.j([]))
|
||||
status="neu", baustein_id=b, ord=0)
|
||||
db.insert("lernziele", topic=topic, id=1, text="Z", status="aktiv")
|
||||
db.insert("sections", baustein_id=b, stage="done", text_kompakt="- k",
|
||||
text_lang=f"<!-- atom: {a} | X -->\n<!-- beispiel: 777 -->\n" + "Wort " * 60)
|
||||
|
||||
Reference in New Issue
Block a user