Skip to content

test(adapters): migrate Vercel Connect webhook tests to connectWebhookContract#673

Open
bensabic wants to merge 1 commit into
mainfrom
tests/connect-contract-adopt
Open

test(adapters): migrate Vercel Connect webhook tests to connectWebhookContract#673
bensabic wants to merge 1 commit into
mainfrom
tests/connect-contract-adopt

Conversation

@bensabic

@bensabic bensabic commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Adopts the shared connectWebhookContract from @chat-adapter/tests in the Slack, GitHub, and Linear suites, replacing the bespoke webhookVerifier blocks (verifier pass → 200, throw/falsy → 401, invoked with request + raw body, precedence over a native secret). Adapter-specific Connect tests are kept (token resolvers, GitHub bot-id capture, type-level mutual exclusivity, 400-on-invalid-JSON, Linear identity/withInstallation).

Each descriptor keeps initialize() network-free (GitHub botUserId, Slack _botUserId to skip auth.test, Linear stubs resolveConnectIdentity). Twilio is intentionally not included — it has a single generic webhookVerifier usage with no 200/401 gating suite to migrate.

First of three stacked test-generalization PRs. Tests-only, no changeset.

Adopt the shared `connectWebhookContract` from `@chat-adapter/tests` in
the Slack, GitHub, and Linear suites, replacing the bespoke
`webhookVerifier` blocks (verifier pass -> 200, throw/falsy -> 401,
invoked with request+body, precedence over a native secret). Keeps
adapter-specific Connect tests (token resolvers, bot-id capture,
type-level mutual exclusivity, 400 on invalid JSON). Twilio is left as-is
(generic verifier, no Connect gating suite to migrate).

Signed-off-by: Ben Sabic <bensabic@users.noreply.github.com>
@bensabic bensabic requested a review from a team as a code owner July 3, 2026 03:31
@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
chat Ready Ready Preview, Comment, Open in v0 Jul 3, 2026 3:32am
chat-sdk-nextjs-chat Ready Ready Preview, Comment, Open in v0 Jul 3, 2026 3:32am

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