test-with-spanner
Run unit tests that require the Spanner emulator. Use this skill when the user wants to run tests in packages like satellite/metabase, satellite/metainfo, or any other tests that interact with Spanner. Automatically handles checking for and configuring the Spanner emulator environment.
Install
mkdir -p .claude/skills/test-with-spanner && curl -L -o skill.zip "https://mcp.directory/api/skills/download/6272" && unzip -o skill.zip -d .claude/skills/test-with-spanner && rm skill.zipInstalls to .claude/skills/test-with-spanner
About this skill
Run Unit Tests with Spanner
You are helping run unit tests that require the Spanner emulator.
Instructions
The Storj test framework automatically manages the Spanner emulator lifecycle using the run: prefix in the STORJ_TEST_SPANNER environment variable.
To run tests automatically spanner_emulator binary needs to be on PATH. Spanner can be also set for tests using -spanner-test-db flag.
Running Tests
-
If test name is provided in arguments:
- Find the package containing the test using Grep
- Run the test with Spanner
-
If only package path is provided:
- Run all tests in that package with Spanner
-
Determine the Spanner connection method:
- First, check if
STORJ_TEST_SPANNERis already set in the environment. If it is, do NOT pass-spanner-test-db— the test framework will pick it up automatically. - Only if
STORJ_TEST_SPANNERis not set, pass-spanner-test-db 'run:spanner_emulator'to auto-manage the emulator.
- First, check if
-
Command format:
# When STORJ_TEST_SPANNER is already set in the environment:
go test -v ./package/path -run TestName
# When STORJ_TEST_SPANNER is NOT set:
go test -v ./package/path -run TestName -spanner-test-db 'run:spanner_emulator'
The run: prefix tells the test framework to:
- Automatically start the Spanner emulator before tests
- Configure the connection for each test
- Clean up and stop the emulator after tests complete
- Report test results:
- Show whether tests passed or failed
- List all subtests that ran
- If tests failed, offer to help investigate the failures
Common test paths
Some common test paths in the Storj codebase:
./satellite/metabase- Metabase tests./satellite/metainfo- Metainfo API tests./satellite/satellitedb- Database tests
Example Usage
# Run a specific test
go test -v ./satellite/metainfo -run TestEndpoint_Object_No_StorageNodes -spanner-test-db 'run:spanner_emulator'
# Run all tests in a package
go test -v ./satellite/metabase -spanner-test-db 'run:spanner_emulator'
# Run tests with timeout
go test -v -timeout 10m ./satellite/metabase -run TestLoop -spanner-test-db 'run:spanner_emulator'
Notes
- Each test gets its own emulator instance that's automatically managed
- No manual cleanup is required - the framework handles emulator lifecycle
- The
run:prefix is the recommended approach used in Storj's CI/CD (see Jenkinsfile.verify and Jenkinsfile.public)
More by storj
View all skills by storj →You might also like
flutter-development
aj-geddes
Build beautiful cross-platform mobile apps with Flutter and Dart. Covers widgets, state management with Provider/BLoC, navigation, API integration, and material design.
drawio-diagrams-enhanced
jgtolentino
Create professional draw.io (diagrams.net) diagrams in XML format (.drawio files) with integrated PMP/PMBOK methodologies, extensive visual asset libraries, and industry-standard professional templates. Use this skill when users ask to create flowcharts, swimlane diagrams, cross-functional flowcharts, org charts, network diagrams, UML diagrams, BPMN, project management diagrams (WBS, Gantt, PERT, RACI), risk matrices, stakeholder maps, or any other visual diagram in draw.io format. This skill includes access to custom shape libraries for icons, clipart, and professional symbols.
ui-ux-pro-max
nextlevelbuilder
"UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient."
godot
bfollington
This skill should be used when working on Godot Engine projects. It provides specialized knowledge of Godot's file formats (.gd, .tscn, .tres), architecture patterns (component-based, signal-driven, resource-based), common pitfalls, validation tools, code templates, and CLI workflows. The `godot` command is available for running the game, validating scripts, importing resources, and exporting builds. Use this skill for tasks involving Godot game development, debugging scene/resource files, implementing game systems, or creating new Godot components.
nano-banana-pro
garg-aayush
Generate and edit images using Google's Nano Banana Pro (Gemini 3 Pro Image) API. Use when the user asks to generate, create, edit, modify, change, alter, or update images. Also use when user references an existing image file and asks to modify it in any way (e.g., "modify this image", "change the background", "replace X with Y"). Supports both text-to-image generation and image-to-image editing with configurable resolution (1K default, 2K, or 4K for high resolution). DO NOT read the image file first - use this skill directly with the --input-image parameter.
fastapi-templates
wshobson
Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.
Related MCP Servers
Browse all serversBMAD streamlines agile project management by uniting business and development teams for efficient delivery using agile p
Boost productivity with Task Master: an AI-powered tool for project management and agile development workflows, integrat
MCP Toolbox for Databases by Google. An open-source server that lets AI agents query Cloud SQL, Spanner, AlloyDB, and ot
Create modern React UI components instantly with Magic AI Agent. Integrates with top IDEs for fast, stunning design and
Empower your Unity projects with Unity-MCP: AI-driven control, seamless integration, and advanced workflows within the U
Guide your software projects with structured prompts from requirements to code using the waterfall development model and
Stay ahead of the MCP ecosystem
Get weekly updates on new skills and servers.