skydoves/android-testing-skills/structuring-a-compose-test
Use this skill to structure a Jetpack Compose UI test class the way androidx itself writes them — `@MediumTest` + `@RunWith(AndroidJUnit4::class)`, a single `createComposeRule(StandardTestDispatcher())` rule, hoisted `mutableStateOf` declared above `setContent { }`, and the Test → Find → Assert → Act → Re-assert flow. Covers when to use `createAndroidComposeRule<MyActivity>()` for custom Activities, how to drive state from outside the composition via `runOnIdle { }`, why state must NOT be hoiste
Agent skill · version 1.0.0 · from skydoves/android-testing-skills
Install
npx yarkr-cli add skill:skydoves/android-testing-skills/structuring-a-compose-testWithout Node.js, on macOS and Linux (curl or wget):
curl -fsSL https://yarkr.com/install.sh | sh -s -- add skill:skydoves/android-testing-skills/structuring-a-compose-test
wget -qO- https://yarkr.com/install.sh | sh -s -- add skill:skydoves/android-testing-skills/structuring-a-compose-testOn Windows, in PowerShell:
irm https://yarkr.com/install.ps1 | iex; yarkr add skill:skydoves/android-testing-skills/structuring-a-compose-testWorks with Claude Code, Codex, opencode, Cursor, any harness over MCP.