test: cover export dump null serialization#165
Open
thedalbee wants to merge 1 commit into
Open
Conversation
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.
/claim #71
Summary
Adds a focused, non-overlapping coverage slice for SQL export dumps in
src/export/dump.ts.Covered behavior:
NULLcell values now serialize as SQLNULLinstead of producing invalid empty INSERT values likeINSERT INTO users VALUES (1, );.This is scoped to export dump generation and intentionally avoids the active CSV/import/RLS/cache/allowlist/operation/worker/handler/DO/LiteREST/plugin coverage PR areas.
Verification
pnpm exec vitest run src/export/dump.test.ts- passed, 7 tests.pnpm exec vitest run src/export/dump.test.ts --coverage.enabled true --coverage.include src/export/dump.ts --coverage.reporter text --coverage.reportsDirectory coverage-export-dump --coverage.thresholds.lines=0 --coverage.thresholds.branches=0 --coverage.thresholds.functions=0 --coverage.thresholds.statements=0- passed;src/export/dump.tsat 100% statements, branches, functions, and lines.pnpm exec prettier --check src/export/dump.ts src/export/dump.test.ts- passed.git diff --check- passed.pnpm exec vitest run- export dump suite passed; current repo baseline still has 4 unrelatedsrc/rls/index.test.tsfailures.pnpm exec tsc --noEmit- current repo baseline has unrelated type errors inplugins/cdc,src/cache/index.test.ts,src/do.test.ts, andsrc/operation.ts.Demo video