Quality Gates
Block PR merges when FixSense detects unresolved test failures.
Overview
Quality Gates adds a GitHub Check to your Pull Request that blocks merging when FixSense detects test failures. Combined with branch protection rules, this ensures no PR is merged with known failing tests.
This moves FixSense from advisory (PR comments) to enforcing — closing the loop:
- CI fails → FixSense analyzes
- Quality Gate check blocks merge
- Auto-fix creates a fix PR (optional)
- Fix verified → check passes → merge allowed
How It Works
When a CI run fails and FixSense analyzes the failures:
- Check created — A "FixSense Quality Gate" check appears on the PR commit with status failure
- Details included — The check summary shows a table of failing tests, root causes, and flakiness scores
- Merge blocked — If branch protection requires this check, the PR cannot be merged
Check Lifecycle
| Event | Check Status | Merge |
|---|---|---|
| Failures detected | Failure | Blocked |
| All failures flaky (quarantine ON) | Neutral | Allowed |
| Auto-fix PR created | Neutral | Depends on branch protection |
| Fix merged + CI green | Success | Allowed |
Setup
Step 1: Enable Quality Gates
- Open your FixSense Dashboard
- Find the Quality Gates toggle in the usage section
- Click to turn it ON
Step 2: Configure Branch Protection (Recommended)
To actually block merges, add the check to your branch protection rules:
- Go to your repository Settings → Branches
- Edit the branch protection rule for your default branch (e.g.,
main) - Under Require status checks to pass, search for FixSense Quality Gate
- Save changes
Without branch protection, the check still appears on PRs as an informational signal — but merging is not blocked.
What the Check Shows
The check summary includes a markdown table with:
- Test name
- Root cause (truncated for readability)
- Flakiness score
This acts as a mini failure dashboard directly in the PR's Checks tab.
Availability
Quality Gates is available on all plans (Free, Pro, Team). It is disabled by default — toggle it on from the dashboard when you're ready.
FAQ
Does this require any GitHub App permission changes?
Yes. The FixSense GitHub App needs checks: write permission. If you installed FixSense before this feature was available, GitHub will prompt you to approve the new permission.
What if the check API call fails? Quality gate errors are handled silently. A failed check creation never blocks your core CI analysis or auto-fix workflow. The worst case is the check doesn't appear — your PR remains unblocked.
Can I use this without auto-fix? Yes. Quality Gates works independently. It blocks merge on any detected failure. Your team can fix the issue manually and push again — the check will re-evaluate on the next CI run.
What about flaky tests? Enable Flaky Quarantine (see below) to automatically pass the quality gate when all failures are flaky. Without quarantine, the check includes flakiness scores so your team can decide how to handle them.
Flaky Quarantine
Flaky tests can block your pipeline even when they're not real regressions. Flaky Quarantine solves this by automatically passing the quality gate when every detected failure is flaky (score 70+).
How It Works
- When quarantine is ON and all failures in a CI run have a flakiness score of 70 or higher, the quality gate check is set to neutral instead of failure
- The check still appears on the PR with full details — but it does not block merge
- If any failure has a flakiness score below 70 (a real regression), the check remains failure and blocks merge as usual
Enable Flaky Quarantine
- First enable Quality Gates in your FixSense Dashboard
- A Flaky Quarantine sub-toggle appears below the Quality Gates toggle
- Click to turn it ON
When to Use
- Your test suite has known flaky tests that you're working on stabilizing
- You want real regressions to block merge, but flaky failures to pass through
- You prefer to track flaky tests via FixSense analytics rather than blocking the pipeline