Repository navigation
Conversation
… threshold - Fix RLS policy parsing for schema-qualified tables and nested subqueries - Add comprehensive test suites for allowlist, csv import, and main router - Expand unit tests and branch coverage for do.ts, handler.ts, and operation.ts - Add cloudflare:workers mock alias and exclude test files from Istanbul coverage - Exceed all global coverage thresholds: 86.85% stmts, 77.21% branches, 83.62% funcs, 87.47% lines - Closes outerbase#71 Signed-off-by: Swapnil Jadhav <yuvi.jadhav92@gmail.com>
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.
Summary
Closes #71
This PR completes the Vitest coverage expansion to satisfy and exceed all required global test coverage thresholds (>= 75% for lines, branches, statements, and functions), bringing the full test suite to 100% green with zero errors across 22 test files and 216 tests.
Changes & Improvements
src/rls/index.ts):public.usersvsusers).fromItem.expr.ast.src/rls/index.test.tsso mock configurations do not leak across test runs.src/allowlist/index.test.ts: Complete coverage for allowlist checks, dynamic additions, and rejections.src/import/csv.test.ts: Complete coverage for CSV stream parsing, delimiter handling, and transactional imports.src/index.test.ts: Complete coverage for worker initialization, routing, execution context handling, and error middleware.src/do.ts: Expanded test coverage for alarm triggers, alarm recovery retry loops, durable object statistics, and WebSocket broadcast cleanup.src/handler.ts: Added validation tests for query route Content-Type enforcement, invalid parameters, and transaction error handling.src/operation.ts: Added tests for external database SDK connections (Postgres, MySQL, Cloudflare D1, Starbase, Turso), hyperdrive connections, raw result transformations, and plugin hooks.vitest.config.ts):cloudflare:workersto provide clean AST parsing during coverage instrumentation.**/*.test.ts) from Istanbul coverage collection.Test Results & Metrics
/claim #71
Signed-off-by: Swapnil Jadhav yuvi.jadhav92@gmail.com