sui-coverage
Analyze Sui Move test coverage, identify untested code, write missing tests, and perform security audits. Includes Python tools for parsing coverage output and generating reports.
Why use this skill?
Improve Sui Move smart contract quality with automated coverage analysis. Identify untested code paths, perform security audits, and generate detailed reports easily.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/easonc13/sui-coverageWhat This Skill Does
The sui-coverage skill is a specialized toolkit for Sui Move developers designed to rigorously audit and enhance the test coverage of smart contracts. By leveraging the Sui CLI's built-in coverage and trace capabilities, this skill provides actionable insights into your codebase, highlighting uncalled functions, untested assertions, and missed branch logic. It bridges the gap between raw coverage data and actionable code by providing Python-based utilities to parse LCOV data and generate human-readable reports, ultimately leading to more robust and secure decentralized applications.
Installation
To integrate this skill into your development workflow, use the OpenClaw skill manager:
clawhub install openclaw/skills/skills/easonc13/sui-coverage
Ensure that the Sui CLI is installed and configured in your system path, as the skill relies on the binary to execute tests and extract coverage metrics. Once installed, verify the installation by checking the contents of your workspace skills directory.
Use Cases
- Security Audits: Identify 'dead' code or unreachable code paths that could potentially hide vulnerabilities.
- CI/CD Integration: Use the JSON output capability to automatically track coverage percentages over time in automated pipelines.
- Test Refactoring: Improve the reliability of existing Move packages by specifically targeting branch coverage for complex state machines.
- Learning: Analyze how the Sui Move compiler interacts with specific logic structures by inspecting byte-code level coverage reports.
Example Prompts
- "OpenClaw, analyze the test coverage for my 'defi-vault' module and generate a report in coverage.md to show me what paths I missed."
- "I'm getting low branch coverage in my 'user_registry' module. Can you run the analysis and suggest unit tests to cover the failure cases for the 'register' function?"
- "Show me the LCOV statistics for the current package and highlight only the files that have less than 80% coverage."
Tips & Limitations
- Environment: Always ensure your
sui move testcommand completes successfully before running the analysis tools. - Context: The
analyze_source.pytool works best when your package structure follows the standard Sui Move conventions (sources folder at the root). - Limitations: While this tool identifies what is not covered, it does not automatically write the Move code for you; it provides the diagnostic data required for you to manually write effective, high-coverage tests. Always manually verify the logic in generated test skeletons.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-easonc13-sui-coverage": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-read, file-write, code-execution
Related Skills
sui-move
Sui blockchain and Move smart contract development. Use when the user asks about Sui, Move language, smart contracts, objects, transactions, or blockchain development on Sui.
sui-knowledge
Answer questions about Sui blockchain ecosystem, concepts, tokenomics, validators, staking, and general knowledge. Use when users ask "what is Sui", "how does Sui work", "Sui vs other chains", or any Sui-related questions that aren't specifically about Move programming.
abstract-searcher
Add abstracts to .bib file entries by searching academic databases (arXiv, Semantic Scholar, CrossRef) with browser fallback.
mac-control
Control Mac via mouse/keyboard automation using cliclick and AppleScript. Use for clicking UI elements, taking screenshots, getting window bounds, handling coordinate scaling on Retina displays, and automating UI interactions like clicking Chrome extension icons, dismissing dialogs, or toolbar buttons.
m3u8-downloader
Download encrypted m3u8/HLS videos using parallel downloads. Use when given an m3u8 URL to download a video, especially encrypted HLS streams with AES-128.