unity-testability

Advises on extracting logic from MonoBehaviour classes and planning Unity EditMode and PlayMode tests.

Updated May 20, 2026
One-click install
npx skills add https://github.com/yuse168/Roomies --skill unity-testability-yuse168
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: unity-testability
Source: https://github.com/yuse168/Roomies/tree/main/.agents/skills/unity-skills/skills/testability
Command: npx skills add https://github.com/yuse168/Roomies --skill unity-testability-yuse168

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Unity code tightly coupled to MonoBehaviour, GameObject, and scene state is hard to unit test. This Skill helps you decide which logic should move into pure C# classes and which should stay Unity-facing, so you can build a practical EditMode/PlayMode test strategy. ## Core Features & Use Cases - Testability Review: Structured review questions to identify logic that can run without Transform, GameObject, or scene state. - Refactoring Guidance: Recommendations for seams, interfaces, and dependency injection to replace static globals. - Test Planning: Suggests candidate EditMode tests for pure logic and PlayMode tests for engine-dependent behavior. - Use Case: You have a 500-line MonoBehaviour mixing game rules with scene references. Use this Skill to identify which rules can be extracted into plain C# classes and get a concrete list of EditMode tests to write first. ## Quick Start Ask the assistant to review your Unity script for testability and suggest which logic to extract into pure C# classes with candidate EditMode and PlayMode tests.

Frequently Asked Questions about unity-testability

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

FAQPage Schema
Can pure C# classes be tested without the Unity engine?▼

Yes, pure C# classes with no UnityEngine dependencies can run under standard EditMode tests and even outside Unity in a plain .NET test project. The key is removing references to engine types like Transform and GameObject.