Skip to content

test: add CSV import route coverage - #161

Open
akamabu wants to merge 1 commit into
outerbase:mainfrom
akamabu:test/csv-import-route-coverage
Open

akamabu wants to merge 1 commit into
outerbase:mainfrom
akamabu:test/csv-import-route-coverage

Conversation

@akamabu

@akamabu akamabu commented May 12, 2026

Copy link
Copy Markdown

/claim #71

Summary

Adds focused Vitest coverage for the CSV import route (src/import/csv.ts).

Covered behaviours:

  • Empty request body returns 400
  • Unsupported Content-Type returns 400
  • Raw text/csv imports generate parameterized insert statements
  • JSON-wrapped CSV payloads apply columnMapping
  • Multipart requests without a file return 400
  • Partial insert failure returns failed statement details

Verification

Not run locally in this environment because dependencies are not installed (node_modules missing). The tests follow the existing JSON import test structure and mock executeOperation the same way.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant