convex-verify

Verify Convex features by seeding data and asserting behavior across multiple mocked user identities.

Updated Sep 17, 2026
One-click install
npx skills add https://github.com/Tehzeeb07/CodeRush --skill convex-verify-tehzeeb07
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: convex-verify
Source: https://github.com/Tehzeeb07/CodeRush/tree/main/.agents/skills/convex-verify
Command: npx skills add https://github.com/Tehzeeb07/CodeRush --skill convex-verify-tehzeeb07

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires convex-test, vitest, @edge-runtime/vm.

What problem does it solve? A passing typecheck only proves Convex code compiles — it does not prove a non-owner is denied access, a query returns the right rows, or a mutation has the intended effect. This Skill closes that gap by running seed → drive → assert verification loops in-process with convex-test, with emphasis on negative authorization assertions that catch the most common real-world defects. ## Core Features & Use Cases - In-process verification with convex-test: Runs tests against your schema without any deployment, using vitest with the edge-runtime environment. - Multi-identity driving: Calls queries and mutations as the owner, a different authenticated user, and an unauthenticated caller via t.withIdentity. - Negative authz assertions: Proves the wrong caller is refused and that list queries never leak another user's rows. - Use Case: After building an owner-only cancel mutation, verify that the owner succeeds, another user is rejected with a forbidden error, and unauthenticated calls fail — catching an authz hole before shipping. ## Quick Start Verify that my new cancelOrder mutation only works for the order owner and rejects other users and unauthenticated callers.

Frequently Asked Questions about convex-verify

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test Convex functions with different user identities?▼

Use t.withIdentity({ subject, tokenIdentifier }) from convex-test to call queries and mutations as different users. Test as the owner, a second authenticated user, and with no identity to cover unauthenticated access.

How to test Convex authorization rules without deploying?▼

Use convex-test with vitest to run tests in-process against your schema, no deployment needed. Seed data for two users, then assert that cross-user calls are rejected with forbidden or not-authorized errors.

Why does convexTest fail with import.meta.glob is not a function?▼

This error occurs when vitest is not configured for convex-test. Set test.environment to "edge-runtime" and add server.deps.inline: ["convex-test"] in vitest.config.ts, and install @edge-runtime/vm.

What should I do when a negative authz test fails?▼

A failing negative assertion means a real authorization hole exists in the function, so fix the access check in the Convex function itself. Never weaken the test assertion just to make it pass.

When should I use convex-verify versus setting up a test framework?▼

Use this Skill to prove a specific built feature behaves correctly, including its authorization rules. For general test framework setup in a project, use a dedicated test-setup capability instead.