Macios CI Failure Inspector
dotnet/macios
Investigate and triage CI failures for dotnet/macios from Azure DevOps build URLs.
Diagnose and fix flaky (intermittently failing) tests in Bitwarden iOS.
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install bitwarden/ios fixing-flaky-tests --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .claude/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .claude/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-testsType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install bitwarden/ios fixing-flaky-tests --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .agents/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .agents/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install bitwarden/ios fixing-flaky-tests --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .cursor/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .cursor/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/bitwarden/ios.git --path .claude/skills/fixing-flaky-tests--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install bitwarden/ios fixing-flaky-tests --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .gemini/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .gemini/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install bitwarden/ios fixing-flaky-testsInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .github/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .github/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add bitwarden/ios --skill fixing-flaky-tests -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install bitwarden/ios fixing-flaky-tests --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bitwarden/ios.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/fixing-flaky-tests .opencode/skills/fixing-flaky-tests && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "fixing-flaky-tests" agent skill from https://github.com/bitwarden/ios/tree/main/.claude/skills/fixing-flaky-tests into .opencode/skills/fixing-flaky-tests/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fixing-flaky-tests", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
fixing-flaky-testsDiagnose and fix flaky (intermittently failing) tests in Bitwarden iOS.
Fixing Flaky Tests is an agent skill from bitwarden/ios, published by the product's own GitHub organization. Diagnose and fix flaky (intermittently failing) tests in Bitwarden iOS. Finds the root cause of non-deterministic test failures (race conditions, timing issues, shared state, order dependence), applies a targeted fix, then stress-tests the fix by running the test 100 times to confirm stability. Use this skill whenever a test is failing intermittently, sometimes passes / sometimes fails, or someone describes a test as flaky, unstable, or non-deterministic — even if the exact cause is unknown. Trigger phrases: "fix…
Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Testing & QA, covering Failing and flaky tests. It works with iOS. The repository describes itself as: Bitwarden mobile apps (Password Manager and Authenticator) for iOS. The licence is GPL-3.0.
7 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 6399b1d. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
xcodebuildFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Fixing Flaky Tests loads about 2.3k tokens when it runs. Until then it costs about 172 tokens; SKILL.md has 934 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from bitwarden/ios at commit 6399b1d, republished under its GPL-3.0 licence (© bitwarden). 934 words, ~2,274 tokens.
.claude/skills/fixing-flaky-tests/SKILL.md (or your agent's skills folder).A flaky test passes sometimes and fails other times without any code change. Flakiness usually comes from a small set of root causes. Your job is to find which one applies, fix it surgically, and then prove the fix holds by running the test many times.
Search for the function name(s) the user provided:
grep -r "func <testFunctionName>" . --include="*.swift" -lNote that:
test_<methodName>_<description> (prefix required by XCTest)@Test macro and can have any name — the test_ prefix is
conventional but not requiredFor each test:
@testable import at the top of the file — that's the module under test
(e.g., @testable import BitwardenShared → module BitwardenShared)| Test target | Scheme | Unit test plan |
|---|---|---|
BitwardenSharedTests, BitwardenTests, BitwardenAutoFillExtensionTests, BitwardenActionExtensionTests, BitwardenShareExtensionTests | Bitwarden | Bitwarden-Unit |
AuthenticatorSharedTests, AuthenticatorTests, AuthenticatorBridgeKitTests | Authenticator | Authenticator-Unit |
BitwardenKitTests | BitwardenKit | BitwardenKit-Unit |
BitwardenKitViewInspectorTests | BitwardenKit | BitwardenKit-ViewInspector |
NetworkingTests | BitwardenKit | BitwardenKit-Default |
When in doubt, search TestPlans/ for the test class name to confirm the plan (and therefore scheme):
grep -r "<TestClassName>" TestPlans/ -lAlways read the simulator config from the project files rather than hardcoding:
DEVICE=$(tr -d '\n' < .test-simulator-device-name)
OS=$(tr -d '\n' < .test-simulator-ios-version)Read the test carefully and the SUT it exercises. Flaky tests in Swift/iOS typically fall into one of these categories:
Race condition / async ordering
The test observes a side effect before the async SUT has finished producing it. Signs: bare
Task.sleep or DispatchQueue.asyncAfter in the test, expectations that time out occasionally,
@MainActor-isolated code whose scheduling the test doesn't account for.
Shared mutable state
State from one test bleeds into the next. Signs: static properties or singletons not reset in
tearDown, NotificationCenter observers not removed, Task or DispatchQueue.async work
from a previous test still running when the next one starts.
Time / date dependence
The SUT reads Date() or Calendar.current inline, so the test result depends on the real clock.
Signs: test passes during the day but fails near midnight, or fails only under heavy load when
wall-clock timing drifts.
Order dependence Test execution order is randomized in the -Default test plans ("testExecutionOrdering" : "random"), but the -Unit plans used for verification here run sequentially. To reproduce order-dependent flakiness, run against the -Default plan rather than -Unit.
Resource contention CoreData, Keychain, or file system state left behind by a previous run.
Replacing bare delays with condition polling: Use the project's test helpers instead of a fixed sleep. These are available to all test targets:
XCTest (subclasses of BaseBitwardenTestCase):
waitFor { condition } — spins the run loop; use when the SUT uses Timer.scheduledTimerwaitForAsync { condition } — polls asynchronously; use for Swift Concurrency-based SUT codeSwift Testing (SwiftTestingHelpers.swift):
try await waitForAsync { condition } — polls asynchronously in @Test functionswaitFor(condition) — spins the run loop in @Test functions using @MainActorawait withContinuationTimeout { resume in … } — wraps callback-based async code so the
test fails cleanly rather than hanging if the callback is never calledShared state:
static var to instance vartearDown / addTeardownBlockNotificationCenter observers: addTeardownBlock { NotificationCenter.default.removeObserver(token) }CoreData / Keychain leaks:
.memory store type when constructing AuthenticatorBridgeDataStore or any CoreData
stack in tests so nothing persists to disk between runsStop before touching production code. Present the plan:
Then ask: "Would you like me to proceed, or would you prefer to handle the SUT change separately?"
The most common SUT fix is replacing an inline Date() or Calendar.current call with an
injected TimeProvider (protocol in BitwardenKit/Core/Platform/Services/TimeProvider.swift),
then using MockTimeProvider in the test.
Only proceed with SUT edits after the user agrees.
Build first so the changes are compiled:
xcodebuild build-for-testing \
-workspace Bitwarden.xcworkspace \
-scheme <SCHEME> \
-destination "platform=iOS Simulator,name=$DEVICE,OS=$OS" \
2>&1 | grep -E "error:|BUILD (SUCCEEDED|FAILED)"Then stress-test the fixed test using -test-iterations, which runs N repetitions in a single
simulator session (far faster than re-launching xcodebuild 100 times):
xcodebuild test-without-building \
-workspace Bitwarden.xcworkspace \
-scheme <SCHEME> \
-only-testing:"<TARGET_NAME>/<TestClassName>/<testFunctionName>" \
-test-iterations 100 \
-test-repetition-mode count-up \
-destination "platform=iOS Simulator,name=$DEVICE,OS=$OS" \
2>&1 | grep -E "(Test Case|Executed|error:|FAILED)" | tail -20<TARGET_NAME> is the test bundle (e.g., BitwardenSharedTests), <TestClassName> is the
class (e.g., MyProcessorTests), and <testFunctionName> is the Swift function name exactly
as written.
Interpreting results:
Executed 100 tests, with 0 failures → fix holds, proceed to Step 6Confirm the fix didn't accidentally break anything else in the same target:
xcodebuild test \
-workspace Bitwarden.xcworkspace \
-scheme <SCHEME> \
-testPlan <SCHEME>-Unit \
-destination "platform=iOS Simulator,name=$DEVICE,OS=$OS" \
2>&1 | grep -E "(Test Suite|error:|FAILED|Executed)" | tail -30The <SCHEME>-Unit plan (e.g., Bitwarden-Unit) excludes snapshot and ViewInspector tests,
keeping the run fast and focused on correctness. If any other test fails, investigate whether the
fix introduced a regression before proceeding.
As the last step, invoke the build-test-verify skill to confirm the full pipeline is clean
(lint, formatter, spell check):
Skill: build-test-verify| Symptom | Likely cause | Fix |
|---|---|---|
Bare try await Task.sleep(…) after triggering async SUT | Side effect races the sleep | Replace with waitForAsync { … } |
Timer.scheduledTimer result observed immediately | Run loop not spinning | Use waitFor { … } (spins run loop) |
| Callback never called → hang | Missing continuation timeout | Use withContinuationTimeout { resume in … } |
static var on subject or dependency | Shared state across tests | Move to instance var, reset in tearDown |
NotificationCenter.addObserver without removeObserver | Observer leaks | addTeardownBlock { NotificationCenter.default.removeObserver(token) } |
Date() / Calendar.current inline in SUT | Wall-clock dependence | Inject TimeProvider; use MockTimeProvider in tests |
waitForExpectations(timeout: 0.1) | Timeout too tight under load | Increase timeout or replace with waitForAsync |
| CoreData state persists across tests | Disk-backed store in tests | Use .memory store type |
© bitwarden, GPL-3.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .claude/skills/fixing-flaky-tests of bitwarden/ios.
Open the folder on GitHubat commit 6399b1d
Fixing Flaky Tests next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Fixing Flaky Tests this skillbitwarden/ios | 695 | — | ~2.3k | Automated safety check: Pass | GPL-3.0 | |
| Macios CI Failure Inspectordotnet/macios | 2.9k | — | ~2.3k | Automated safety check: Pass | Custom licence | |
| Codex Local CLI E2Erebornix/Agmente | 545 | — | ~625 | Automated safety check: Pass | MIT | |
| Fix Random CI Test Failuredotnet/macios | 2.9k | — | ~1.3k | Automated safety check: Pass | Custom licence | |
| Diagnosing Bugsgetsentry/sentry-react-native | 1.8k | — | ~1.4k | Automated safety check: Pass | MIT | |
| MAUI UI Test Writerdotnet/maui | 23k | — | ~3k | Automated safety check: Pass | MIT |
dotnet/macios
Investigate and triage CI failures for dotnet/macios from Azure DevOps build URLs.
rebornix/Agmente
Run and debug Agmente iOS end-to-end tests against a real local Codex CLI app-server instance.
dotnet/macios
Investigate and fix flaky/random CI test failures in dotnet/macios.
getsentry/sentry-react-native
A discipline for hard bugs, flaky tests, CI hangs, native crashes, and performance regressions in this SDK.
dotnet/maui
Writes UI tests that reproduce a GitHub issue in .NET MAUI and keeps iterating until the tests actually fail, proving they catch the bug.
woocommerce/woocommerce-ios
Debug a failing test or build error in WooCommerce iOS. An agent skill from woocommerce/woocommerce-ios.
bitwarden/ios
Write tests, add test coverage, unit test, or add missing tests for Bitwarden iOS.
bitwarden/ios
Build the Bitwarden iOS app, capture all compiler and lint warnings, categorize them into Swift 6 concurrency vs actionable, and interactively fix the actionable ones.
bitwarden/ios
Build the project, run tests, lint, format, spell check, generate mocks, or verify the build passes for Bitwarden iOS.
bitwarden/ios
Convert a hand-written bespoke mock to a Sourcery AutoMockable-generated mock.
bitwarden/ios
Evaluates a bitwarden/ios "Update SDK to" PR against the sdk-swift commit range for compile-time, runtime and serialization breaking changes, maps affected symbols to iOS call sites, and applies…
bitwarden/ios
Implement, write code, add a new screen, create a feature, new view, new processor, or wire up a new service in Bitwarden iOS.
Works with
Categories
Diagnose and fix flaky (intermittently failing) tests in Bitwarden iOS. Fixing Flaky Tests is an agent skill from bitwarden/ios, published by the product's own GitHub organization. Diagnose and fix flaky (intermittently failing) tests in Bitwarden iOS.
Fixing Flaky Tests fits situations like: A test is failing intermittently; sometimes passes / sometimes fails; someone describes a test as flaky; non-deterministic — even if the exact cause is unknown.
Run `npx skills add bitwarden/ios --skill fixing-flaky-tests -a claude-code`. Or copy the skill folder (.claude/skills/fixing-flaky-tests in bitwarden/ios) into .claude/skills/fixing-flaky-tests in your project. Claude Code loads it when a task matches its description.
Run `npx skills add bitwarden/ios --skill fixing-flaky-tests -a codex`. Or copy the skill folder (.claude/skills/fixing-flaky-tests in bitwarden/ios) into .agents/skills/fixing-flaky-tests in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add bitwarden/ios --skill fixing-flaky-tests -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/fixing-flaky-tests, .gemini/skills/fixing-flaky-tests, .github/skills/fixing-flaky-tests and .opencode/skills/fixing-flaky-tests in your project.
Going by SKILL.md and its folder, Fixing Flaky Tests needs the command-line tools its instructions call (xcodebuild).
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Fixing Flaky Tests is published under the GPL-3.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.3k tokens (SKILL.md is roughly 9.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Fixing Flaky Tests: Macios CI Failure Inspector (dotnet/macios, 2.9k stars), Codex Local CLI E2E (rebornix/Agmente, 545 stars), Fix Random CI Test Failure (dotnet/macios, 2.9k stars) and Diagnosing Bugs (getsentry/sentry-react-native, 1.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
bitwarden (a GitHub organization, an official publisher) maintains it in bitwarden/ios, which has 695 GitHub stars. The repository holds 11 skills in this directory. The repository was last updated on October 7, 2026.
Source: bitwarden/ios on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.