Skip to content

test(integration): port delete operations tests to self-contained framework#761

Draft
kriszyp wants to merge 2 commits into
mainfrom
claude/api-tests-delete
Draft

test(integration): port delete operations tests to self-contained framework#761
kriszyp wants to merge 2 commits into
mainfrom
claude/api-tests-delete

Conversation

@kriszyp
Copy link
Copy Markdown
Member

@kriszyp kriszyp commented May 23, 2026

Summary

  • Ports 8_deleteTests.mjs (76 tests) to the new per-suite isolated Harper instance pattern in integrationTests/apiTests/delete.test.mjs
  • Each suite starts its own Harper instance via startHarper/teardownHarper
  • before() creates all required fixtures: northnwd.employees, dev.rando (4 pre-seeded records), and numeric-string schemas 123.4/1123.1 that the legacy suite inherited from 1_environmentSetup.mjs
  • Uses awaitJob/getJobId from utils/operations.mjs for async job polling

Attention areas

  • The delete_files_before tests depend on a insertTimestamp variable captured between two insert batches — this replaces the legacy testData.insert_timestamp mutable shared state. The timing is tight: we capture the ISO timestamp immediately before the second batch, which should be sufficient but is worth verifying on slow CI runners.
  • The setTimeout delays from the legacy file are preserved (27s total). These were in the original for disk-async reasons; I left them rather than risk flakiness, but they could be reduced in a follow-up if CI confirms they're unnecessary.
  • Codex (P1) and Gemini both flagged the missing numeric-string schema fixtures — fixed in the second commit.

🤖 Generated by Claude Sonnet 4.6

kriszyp and others added 2 commits May 22, 2026 21:45
…mework

Ports 8_deleteTests.mjs (76 tests) to the new per-suite isolated Harper
instance pattern. Creates its own northnwd.employees and dev.rando fixtures
in before(); uses awaitJob/getJobId from utils/operations.mjs for async
job polling.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add create_schema/create_table for numeric-string schemas '123'/'1123'
  and their tables in before() — these were created by 1_environmentSetup.mjs
  in the legacy shared suite but missing from the self-contained port
- Fix search_by_hash in 'Verify object and array records deleted': last
  hash_value was duplicated 7925 instead of 7927

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@kriszyp kriszyp requested a review from Ethan-Arrowood May 23, 2026 03:51
@claude
Copy link
Copy Markdown
Contributor

claude Bot commented May 23, 2026

Reviewed; no blockers found.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant