Skip to content

moooon

Motir

Vibe your whole project. Bring an idea — Motir's three AI layers plan it, track it, and ship it, end to end. You're looking at Motir, built in Motir.

  • Vibe Project
  • Open Source
  • AI Agent
  • AI Loop
1
requests
0
upvotes
145
planned
1,361
shipped

Motir · Work items

MOTIR-3303Done

Integration test — two cards in ONE pass draw different lesson sets

The assembled-behaviour test for the story: prove the query actually varies WITHIN a pass, which is the property the old design could not have.

Seed a store with lessons of at least two categories, then run one deepen pass over two cards of different type and assert their selected lessonIds differ. Doing it inside one pass is the whole point — two separate passes would differ under the old per-job query too, so a test that used two passes would pass before this story's change and prove nothing.

Also pin the inspection property: the job record carries the selected ids per card, not one set for the pass, so a reader can answer "which lessons did THIS card see?".

Acceptance criteria

  • One pass, two cards of different type, different selected lessonIds — asserted on ids, not rendered prose.
  • The same suite fails when the query is reverted to a per-pass string, recorded in the PR body.
  • The job record holds the selected ids per card, asserted.
  • A card whose query matches nothing still yields an empty promptSection, and the pass completes.
  • Only the changed files are run locally; CI runs the suite.

Context refs

  • motir-ai tests/plannerInputs.test.ts, tests/lessonInjection.test.ts — the harnesses to extend.
  • motir-ai src/jobs/plannerInputs.ts — the pass loop under test.
  • MOTIR-3302 — the helper this exercises.