Repository navigation
issue-tracker: todoist fixture recorder, replay scenario and adapter check - #65
Merged
Merged
Conversation
…check Everything for the todoist mock-proxy fixture up to the part that needs a live Todoist account. It builds on PR #48's fixture registry and lives in the issue-tracker plugin folder, whose lane names todoist (strict plugin folder containment). - issue-tracker/fixtures/todoist/record.mjs fetches the catalog document from the real proxy (public, no token needed). With TODOIST_TOKEN set, it also records /api/v1/projects and /api/v1/tasks as paged, redacted api/GET__api__v1__<collection>__page-<n>.json files. The redaction list is exported as REDACTIONS and documented in the file header. It fails closed: any string field it does not know is replaced and listed in api/meta.json. Output is formatted with the repo's oxfmt. - document.yaml was recorded here from https://localthought.io/catalog/todoist.yaml on 2026-09-23 (oxfmt only re-indented YAML lists). - scenario.mjs implements the fixtures/index.mjs interface. It replays api/ by cursor, reads by id from the recorded rows, and returns 403 on writes, like the real data:read catalog. - issue-tracker/todoist-fixture.test.ts runs in the issue-tracker unit tier. It checks the recorder's redaction on every run. Once api/ exists, it also checks that every field localthought/todoist.ts reads is present and typed, runs the rows through todoistProjection, replays pagination, and asserts the fixture is registered. Not done: api/ is not recorded, because there were no Todoist credentials. todoist is also not registered in localthought/fixtures/index.mjs (PR #48's file), since an unrecorded fixture must not be served. The command and the follow-up edits (index.mjs import from ../../issue-tracker/..., and mock-proxy.test.mjs) are in record.mjs's header. Refs #46. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
michielbdejong
marked this pull request as ready for review
September 23, 2026 09:18
michielbdejong
force-pushed
the
claude/issue-46-todoist-fixture
branch
from
September 23, 2026 09:18
aafb66c to
25d46e5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft. Depends on #48, and is based on its branch (
claude/atomic-plugins-issue-43-1b43ea). Rebase ontomainonce #48 merges.This covers everything for the todoist mock-proxy fixture except the step that needs a live Todoist account. Following #48's layout, all files live in the issue-tracker plugin folder:
integrations/issue-tracker/fixtures/todoist/record.mjsis the recorder.document.yamlfrom the real proxy (https://localthought.io/catalog/todoist.yaml, which is public and needs no token).TODOIST_TOKENset, it also records/api/v1/projectsand/api/v1/taskspage by page intoapi/GET__api__v1__<collection>__page-<n>.json, plusapi/meta.json.REDACTIONSand documents in its file header. IDs become consistent fakes (task-1,project-2), and user-written text and labels are replaced.meta.json.document.yamlwas recorded on 2026-09-23. The only change from the served file is oxfmt re-indenting YAML lists.scenario.mjsimplements thefixtures/index.mjsinterface. It replays pages by cursor, serves single rows by id from the recorded pages, and returns 403 on writes, like the real read-only (data:read) catalog.integrations/issue-tracker/todoist-fixture.test.tsruns in the issue-tracker lane's unit tier.api/exists, five more check that every fieldlocalthought/todoist.tsreads is present and correctly typed, run the rows throughtodoistProjection, replay pagination, and check that todoist is registered.todoist is not registered in
integrations/localthought/fixtures/index.mjsyet. An unrecorded fixture must not be served, somock-proxy.test.mjsstill uses todoist as its example of a missing fixture.Verified
Against a local copy of atomic-server at the pinned
.atomic-server-ref:mock-proxy.test.mjs: 3 of 3 passed. oxlint and oxfmt are clean onintegrations/issue-tracker.MOCK_PROXY_PLATFORMS=github-issues,todoist. Removingcheckedfrom a recorded task made the adapter checks fail, as intended.Not verified
record.mjs.Refs #46
🤖 Generated with Claude Code