Add E2E integration test for Cartridge API server#448
Draft
Conversation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Instead of constructing session files from env vars, copy the actual controller CLI storage directory and rewrite session_rpc_url to point at the local Katana node. This matches the real file layout the CLI uses (@cartridge/ directory structure with typed JSON envelopes). 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.
This test validates the full Cartridge controller flow end-to-end against a local Katana node loaded from the pre-migrated spawn-and-move DB: authenticating a controller account via the real Cartridge API (
api.cartridge.gg), routing transactions through a real paymaster sidecar, and executing Dojo contract functions (spawn/move) on-chain via outside execution (SNIP-9). The controller CLI is used as a convenient interface to drive the flow, standing in for what would normally be the web-based controller UI.The test is a standalone binary at
tests/controller/and gracefully skips (exit 0) when prerequisites are missing.A
cartridgefeature was added tokatana-utilsto allowTestNodeto be built with full Cartridge API support.🤖 Generated with Claude Code