sui-build

Build and test Sui Move packages with environment targeting and coverage.

10|5|Updated Mar 13, 2026
One-click install
npx skills add https://github.com/MystenLabs/skills --skill sui-build
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: sui-build
Source: https://github.com/MystenLabs/skills/tree/main/sui-build-test
Command: npx skills add https://github.com/MystenLabs/skills --skill sui-build

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill helps users build and test Sui Move packages reliably by explaining the correct build and test workflows, including environment targeting, coverage, and debugging options.

Core Features & Use Cases

  • Build Sui Move Packages: Compile Move modules, validate types, enforce resource safety, and produce bytecode via the standard build command.
  • Test with Realistic Scenarios: Run unit and scenario-style tests, including multi-transaction/multi-sender flows, plus assertions using unit test facilities.
  • Target the Right Network: Use build and test environment selection when Move.toml defines multiple environments.
  • Verify Quality with Coverage & Tooling: Generate code coverage and inspect module-level coverage, plus enable Move Analyzer in VS Code for faster iteration.
  • Debug Execution Failures: Use trace debugging, replay past transactions locally, and print values during test runs to pinpoint issues.

Quick Start

Run the build and fix any compilation or type errors before testing by telling the agent: Build my Sui Move package with sui move build and help me resolve any errors.

Frequently Asked Questions about sui-build

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

FAQPage Schema
How do I build and test a Sui Move package locally?

To build and test a Sui Move package, compile the modules using sui move build to validate types and resource safety, then execute unit tests and multi-transaction scenarios with sui move test to verify execution logic.

Can I target a specific network environment when building Sui Move packages?

Yes, you can target specific network environments during the Sui Move build and test processes by using the --build-env flag when your Move.toml configuration defines multiple environments for deployment.

What is the best way to debug Sui Move test failures?

The best way to debug Sui Move test failures is to use trace debugging, print variable values during test execution, and replay past transactions locally to pinpoint execution issues and resource safety violations.

How do I generate and inspect code coverage for Sui Move modules?

You generate and inspect Sui Move code coverage by running the coverage command to produce module-level coverage reports, verifying which execution paths and resource operations your unit tests successfully exercise.

Does Move Analyzer work with Sui Move packages for faster iteration?

Yes, Move Analyzer integrates with Sui Move packages to provide faster iteration and development feedback, enabling features like code inspection and type checking directly within supported environments such as VS Code.

Why does my Sui Move build fail with resource safety errors?

A Sui Move build fails with resource safety errors when the compiler detects violations in how digital assets are moved or copied, requiring you to fix module type definitions and resource operations before testing.