You'll typically receive a Tuist test case URL or identifier. Follow these steps to investigate and fix it:
Works with
AI-first code editor with Composer
Before installing skills in Cursor, ensure your development environment meets these requirements:
node --versionfix-flaky-testsExecute the skills CLI command in your project's root directory to begin installation:
Fetches fix-flaky-tests from tuist/agent-skills and configures it for Cursor.
The CLI shows a list of agents. Use arrow keys and space to select Cursor:
Confirm successful installation by checking the skill directory location:
Restart Cursor to activate fix-flaky-tests. Access via /fix-flaky-tests in your agent's command palette.
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Submit your Claude Code skill and start earning
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
Save 3-5 hours per week on routine tasks
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
Accelerate learning and skill development by 2x
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
Improve work quality by 30-40% with less effort
0
total installs
0
this week
28
GitHub stars
0
upvotes
Run in your terminal
0
installs
0
this week
28
stars
You'll typically receive a Tuist test case URL or identifier. Follow these steps to investigate and fix it:
tuist test case show <id-or-identifier> --json to get reliability metrics for the test.tuist test case run list Module/Suite/TestCase --flaky --json to see flaky run patterns.tuist test case run show <test-case-run-id> --json on failing flaky runs to get failure messages and file paths.If no specific test is provided, start with the Discovery section below.
When no specific test case is provided, find all flaky tests in the project:
tuist test case list --flaky --json --page-size 50
This returns all test cases currently flagged as flaky. Key fields:
module.name / suite.name / name — the test identifieravg_duration — helps prioritize (fix fast unit tests first)is_quarantined — whether the test is already quarantinedTriage strategy:
test_run_id — tests that all failed in the same run may have been killed by a process crash, not individual test bugs.You can pass either the UUID or the Module/Suite/TestCase identifier:
tuist test case show <id> --json
tuist test case show Module/Suite/TestCase --json
Key fields:
reliability_rate — percentage of successful runs (higher is better)flakiness_rate — percentage of runs marked flaky in the last 30 daystotal_runs / failed_runs — volume contextlast_status — current statetuist test case run list Module/Suite/TestCase --flaky --json
The identifier uses the format ModuleName/SuiteName/TestCaseName or ModuleName/TestCaseName when there is no suite. This returns only runs that were detected as flaky.
tuist test case run list Module/Suite/TestCase --json --page-size 20
Look for patterns:
is_ci: true) or also locally?tuist test case run show <test-case-run-id> --json
Key fields:
failures[].message — the assertion or error messagefailures[].path — source file pathfailures[].line_number — exact line of failurefailures[].issue_type — type of issue (assertion_failure, etc.)repetitions — if present, shows retry behavior (pass/fail sequence)test_run_id — the broader test run this execution belongs tocrash_report — crash report data (present when the test runner crashed); contains exception_type, signal, exception_subtype, and triggered_thread_framesfailures[0].path and go to failures[0].line_number.await, expectations with timeouts, or polling.sleep(1) or fixed delays that are too short on CI. Fix: use condition-based waits instead of fixed delays.crash_report)EXC_BREAKPOINT / SIGTRAP — force-unwrap of nil, Swift precondition failureEXC_BAD_ACCESS / SIGSEGV — use-after-free or dangling pointerEXC_CRASH / SIGABRT — uncaught Objective-C exceptionAfter identifying the pattern:
Run the specific test repeatedly until failure using xcodebuild's built-in repetition support:
xcodebuild test -workspace <workspace> -scheme <scheme> -only-testing <module>/<suite>/<test> -test-iterations <count> -run-tests-until-failure
This runs the test up to <count> times and stops at the first failure. Choose the iteration count based on how long the test takes — for fast unit tests use 50–100, for slower integration or acceptance tests use 2–5.
Before applying a fix, try to reproduce the flaky failure locally. A successful reproduction confirms your root cause analysis and lets you verify the fix directly. Use the "Running tests repeatedly" approach above, or the race condition strategies below if concurrency is suspected.
Some flaky scenarios — especially race conditions, CI-specific timing issues, or environment-dependent failures — may be difficult or impossible to reproduce locally. If you cannot reproduce after reasonable effort, proceed with fixing based on code analysis and failure logs. A fix backed by clear evidence of a bug (e.g. unsynchronized shared state, TOCTOU pattern) is valid even without local reproduction.
Race conditions and concurrency bugs often only manifest under CI-level parallelism and are hard to reproduce locally. Try these strategies in order:
-parallel-testing-enabled YES to run test suites concurrently.-only-testing ModuleTests) to increase contention on shared resources.xcodebuild test -workspace <workspace> -scheme <scheme> -only-testing <module> -enableThreadSanitizer YES
If a race condition cannot be reproduced locally but the code is provably thread-unsafe (e.g. unsynchronized mutation of shared state), the fix is still valid. Verify the fix by confirming the tests pass with the same reproduction strategies above. Document in the commit message that the fix addresses a CI-only race condition identified through code analysis and failure logs.
Prerequisites
Time Estimate
15-45 minutes depending on use case complexity
Steps
Common Pitfalls
✓ Do
✗ Don't
💡 Pro Tips
✓ Use when
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
✗ Avoid when
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
cexll/myclaude
github/awesome-copilot
microsoft/playwright-cli
aj-geddes/useful-ai-prompts
github/awesome-copilot
refoundai/lenny-skills
Registry listing for fix-flaky-tests matched our evaluation — installs cleanly and behaves as described in the markdown.
Useful defaults in fix-flaky-tests — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
I recommend fix-flaky-tests for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.
Useful defaults in fix-flaky-tests — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
fix-flaky-tests fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.
fix-flaky-tests is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
Keeps context tight: fix-flaky-tests is the kind of skill you can hand to a new teammate without a long onboarding doc.
fix-flaky-tests is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
fix-flaky-tests is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
Keeps context tight: fix-flaky-tests is the kind of skill you can hand to a new teammate without a long onboarding doc.
showing 1-10 of 64