migrate-harness-tests-to-state-transition-test
OfficialModernize charm tests for Juju compatibility.
Authorcanonical
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill helps charm developers update their unit tests from the deprecated ops.testing.Harness framework to the modern, event-driven state-transition tests, ensuring compatibility with current Juju releases.
Core Features & Use Cases
- Harness Detection: Identifies all usages of
ops.testing.Harnessand related helpers within your test suite. - Guided Migration: Provides step-by-step instructions and recipes for rewriting tests to model Juju events and states accurately.
- Use Case: You have a charm with many unit tests still using
Harness. This Skill will guide you through systematically replacing them with state-transition tests, ensuring your charm's test suite remains functional and maintainable.
Quick Start
Run the provided script to find all remaining Harness usages in your tests.
Dependency Matrix
Required Modules
None requiredComponents
scriptsreferences
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: migrate-harness-tests-to-state-transition-test Download link: https://github.com/canonical/copilot-collections/archive/main.zip#migrate-harness-tests-to-state-transition-test Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.