Conversation
Add test/e2e.test.ts with 17 tests that exercise the full TypeScript pipeline: handleRequest() → real Client (pg-client.ts) → wire protocol → MockTransport. Tests cover GET/POST /users routes, error cases (400/404/500), Content-Type validation, and connection failures. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Fix 405 route matching in handler.js to match handler-logic.ts behavior: paths like /users/1/settings now correctly return 404 (not found) instead of 405 (method not allowed). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
All 61 tests pass (17 new E2E + 44 existing). Typecheck clean. All acceptance criteria for US-405 met. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds a focused test for the distinct routing branch that handles unsupported HTTP methods on parameterized /users/:id paths (e.g. DELETE /users/1), which follows a different code path than /users. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Accept main's US-602 plan as the current implementation plan. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.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 #54
test/e2e.test.ts) that exercise the full TypeScript pipeline:handleRequest()→ realClient(pg-client.ts) → Postgres wire protocol (pg-wire.ts) → MockTransporthandler.jsrouting withhandler-logic.tsfor consistent 405/404 edge case behaviorChanges
test-apps/t4-ts-http-postgres/test/e2e.test.tstest-apps/t4-ts-http-postgres/src/handler.js.tervezo/IMPLEMENTATION_PLAN.mdAcceptance Criteria
Test plan
npm run typecheckpassesnpm testpasses — 61/61 tests (17 new E2E + 44 existing)🤖 Generated with Claude Code