Bitbucket Cloud
Connect FixSense to your Bitbucket Cloud pipelines for automated test failure analysis.
Overview
FixSense supports Bitbucket Cloud alongside GitHub, GitLab, and Azure DevOps. When a Playwright or Cypress pipeline fails on Bitbucket, FixSense automatically downloads artifacts, parses test results, and delivers AI-powered root cause analysis.
Requirements
- A Bitbucket Cloud repository with Playwright or Cypress tests
- Admin access to the repository (for webhook registration)
- Bitbucket Pipelines enabled on the repository
- Test framework configured with a JUnit XML reporter
- CI pipeline configured to upload test results as artifacts
Test Reporter Configuration
// playwright.config.ts
export default defineConfig({
reporter: [
['html'],
['junit', { outputFile: 'test-results/results.xml' }],
],
});Pipeline Artifact Upload
# bitbucket-pipelines.yml
pipelines:
default:
- step:
name: Run Tests
image: mcr.microsoft.com/playwright:v1.58.2-noble
script:
- npm ci
- npx playwright test
artifacts:
- test-results/**Bitbucket Pipelines artifacts are automatically available to FixSense — no extra configuration needed beyond listing the artifact paths in your pipeline.
Setup
Step 1: Sign in with Bitbucket
Go to the FixSense login page and click Sign in with Bitbucket. This grants FixSense read access to your Bitbucket profile and repositories.
Step 2: Connect your repository
- Open the Setup page
- FixSense will load your Bitbucket repositories automatically
- Select the repository you want to connect
- Click Connect Repository
FixSense will automatically:
- Register a webhook on the repository for pipeline completion events
- Save the configuration
Step 3: Trigger a pipeline
Push a commit or run a pipeline manually. When a test fails, FixSense will:
- Receive the pipeline completion webhook
- Download test artifacts from the failed pipeline step
- Parse the JUnit XML test report
- Run AI analysis on each failure
- Post results to the dashboard (and optionally as PR comments)
Features
All core FixSense features work with Bitbucket:
| Feature | Bitbucket Support |
|---|---|
| AI failure analysis | Yes |
| Flakiness scoring | Yes |
| PR comments | Yes (via Pull Request Comments API) |
| Quality gates | Yes (via Commit Status API) |
| Slack notifications | Yes |
| Dashboard | Yes |
| Auto-fix agent | Yes |
Bitbucket vs GitHub Differences
| GitHub | Bitbucket | |
|---|---|---|
| Auth | GitHub App (automatic) | Bitbucket OAuth |
| Webhook | Auto-registered by GitHub App | Auto-registered during setup |
| Quality gate | Checks API (check run) | Commit Status API |
| PR comments | Pull Request reviews | PR Comments API |
| Artifact format | GitHub Artifacts API | Pipeline step log artifacts |
| Auto-fix | GitHub Actions workflow | Custom pipeline trigger |
Auto-Fix on Bitbucket
FixSense can automatically fix failing tests on Bitbucket using a custom pipeline. To enable auto-fix:
Step 1: Add the fix pipeline to your repository
Add a custom pipeline to your bitbucket-pipelines.yml:
pipelines:
custom:
fixsense-fix:
- step:
name: FixSense Auto-Fix
image: mcr.microsoft.com/playwright:v1.58.2-noble
script:
- echo "FixSense auto-fix pipeline"
# The auto-fix agent will be triggered by FixSense
artifacts:
- test-results/**Step 2: Enable auto-fix in the dashboard
- Go to the Dashboard
- Open Settings
- Toggle Auto-Fix to enabled
- Provide your AI API key for the fix agent
When a test fails, FixSense will trigger the custom pipeline, run the AI fix agent, and create a pull request with the proposed fix.
Auto-fix uses your Bitbucket Pipeline minutes. Each fix attempt typically takes 2-5 minutes depending on test complexity.
Alternative: FixSense Pipe
You can also add FixSense as a Bitbucket Pipe — a standalone pipeline step that sends test results for analysis:
pipelines:
default:
- step:
name: Run Tests
script:
- npm ci
- npx playwright test
artifacts:
- test-results/**
- step:
name: FixSense Analysis
script:
- pipe: docker://sgace11/fixsense-pipe:0.1.0
variables:
FIXSENSE_API_KEY: $FIXSENSE_API_KEY
RESULTS_PATH: "test-results/**"This works alongside the webhook integration — use whichever fits your workflow. The pipe is useful if you prefer explicit pipeline steps over automatic webhook-based analysis.
Troubleshooting
No repositories appear during setup
Make sure you have Admin access to at least one Bitbucket repository. FixSense only shows repositories where you can manage webhooks.
No analyses appear after pipeline failure
- Check that your
bitbucket-pipelines.ymlincludestest-results/**in theartifactssection - Verify your test framework config includes a JUnit XML reporter
- Check that the pipeline completed with FAILED or STOPPED status
- Verify the webhook exists: Repository Settings > Webhooks
"Invalid grant" error when signing in
This usually means the Bitbucket OAuth session expired. Sign out of FixSense and sign in again with Bitbucket.
Auto-fix pipeline not triggering
- Verify the custom pipeline
fixsense-fixexists in yourbitbucket-pipelines.yml - Make sure the pipeline is committed and pushed to the default branch
- Check that auto-fix is enabled in the FixSense dashboard settings