CtrlK
BlogDocsLog inGet started
Tessl Logo

testland/unity-test-framework

Author and run the Unity game-engine Test Framework (`com.unity.test-framework`, currently v1.8). Distinct from the ThrowTheSwitch Unity C testing library at throwtheswitch.org/unity - the two tools share only a name. Covers package install via Package Manager, the EditMode vs PlayMode split, the [Test] / [UnityTest] / [SetUp] / [TearDown] / [UnityPlatform] attributes, assembly-definition setup (Editor folder vs asmdef with `includePlatforms` / `optionalUnityReferences: [TestAssemblies]`), Test Runner window, command-line batch invocation with `-runTests` / `-testPlatform` / `-testResults` / `-testFilter` / `-testCategory`, NUnit 3.5 assertion API, and CI integration. Use when the unit under test is C# Unity code that needs to exercise the Unity runtime or editor.

74

Quality

93%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

High

Do not use without reviewing

Overview
Quality
Evals
Security
Files

attributes.mdreferences/

UTF attribute cheatsheet - reference

Attributes for unity-test-framework, per the v1.4 manual index and the NUnit 3.5 docs the framework wraps.

AttributePurposeSource
[Test]Plain NUnit test - synchronousNUnit; recommended default per edit-mode-vs-play-mode docs
[UnityTest]Coroutine-style test that can yield frames / seconds in PlayMode or skip frames in EditModeUTF-specific
[SetUp] / [TearDown]Per-test fixture setup / cleanupNUnit
[OneTimeSetUp] / [OneTimeTearDown]Once-per-fixture setup / cleanupNUnit
[TestFixture]Marks a class as containing tests (optional in NUnit 3)NUnit
[Category("Smoke")]Tag a test for filteringNUnit; selectable via CLI -testCategory
[UnityPlatform(RuntimePlatform.WindowsPlayer)]Restrict test to specific runtime platformsUTF-specific
[ValueSource(nameof(MyCases))]Parameterised inputsNUnit; ValueSource is supported per the v1.4 manual (other parameterised attributes have known limitations - see the skill's Limitations section)

SKILL.md

tile.json