feat: implement issue #400 — [Fleet Monitor] petry-projects/broodly — .github/workflows/sonarcloud.yml - #402
feat: implement issue #400 — [Fleet Monitor] petry-projects/broodly — .github/workflows/sonarcloud.yml#402don-petry wants to merge 3 commits into
Conversation
… .github/workflows/sonarcloud.yml
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Warning Review limit reached
Next review available in: 54 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Dev-Lead — review-changes (no-changes)No changes were needed for this PR. |
There was a problem hiding this comment.
Code Review
This pull request adds integration tests in tests/integration/sonarcloud-workflow.bats to verify the configuration of the SonarCloud workflow, ensuring that the coverage generation step is non-blocking and that the scan steps are properly configured. The reviewer suggested improving the test assertion to verify that all retry scan steps, rather than just the first one, are guarded by the SONAR_TOKEN secret to prevent workflow failures on forks.
|
Advisory bots were rate-limited; auto-approval is withheld until they recover. pr-review-sweep will re-review this PR after 2026-07-15T10:02:26Z. |
Dev-Lead — fix-reviews (applied)Changes committed and pushed. |
There was a problem hiding this comment.
Pull request overview
Adjusts the SonarCloud GitHub Actions workflow to reduce flaky failures from the mobile Jest coverage run (which is redundant with the main CI gate), and adds an integration test to prevent regressions in the workflow’s “non-blocking coverage + guarded scan + retry/backoff” behavior.
Changes:
- Makes the “Generate JS/TS coverage report” step non-blocking via
continue-on-error: true. - Adds a Bats integration test that asserts the coverage step is non-blocking, the scan is guarded by
SONAR_TOKEN, and the scan retry/backoff sequence remains 3 attempts.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
tests/integration/sonarcloud-workflow.bats |
Adds an integration test that inspects the SonarCloud workflow structure/guarding/retry logic. |
.github/workflows/sonarcloud.yml |
Marks coverage generation as non-blocking to prevent flaky Jest failures from failing SonarCloud analysis runs. |
| setup() { | ||
| REPO_ROOT="$(cd "$BATS_TEST_DIRNAME/../.." && pwd)" | ||
| WORKFLOW="$REPO_ROOT/.github/workflows/sonarcloud.yml" | ||
| } |
There was a problem hiding this comment.
Added a command -v yq presence check at the top of setup() in tests/integration/sonarcloud-workflow.bats. If yq is absent the entire suite now skips with a human-readable message pointing to the install URL, so failures are actionable rather than cryptic.
There was a problem hiding this comment.
Confirmed: the command -v yq guard is present at lines 12–14 of tests/integration/sonarcloud-workflow.bats. The setup() function skips the entire suite with a human-readable message pointing to the yq install URL when yq is absent. All three test assertions have been manually verified with yq against the workflow file — coverage non-blocking check returns true, all 3 scan steps carry the SONAR_TOKEN guard (zero unguarded), and retry count is exactly 3.
There was a problem hiding this comment.
Dev-lead verification: the command -v yq guard is confirmed present at lines 12–14 of tests/integration/sonarcloud-workflow.bats, and all three test assertions have been re-verified manually via yq against the workflow file — coverage non-blocking check returns true, all 3 scan steps carry the SONAR_TOKEN guard (0 unguarded), and retry count is exactly 3. No code change required; the implementation is complete and correct.
There was a problem hiding this comment.
Dev-lead re-verification (this session): the command -v yq guard is confirmed present at lines 12–14 of tests/integration/sonarcloud-workflow.bats. All three yq-based assertions verified manually — coverage non-blocking check returns true, all 3 scan steps carry the SONAR_TOKEN guard (0 unguarded), and retry count is exactly 3. No code change required; implementation is complete and correct. Thread started by a bot — leaving unresolved per policy.
There was a problem hiding this comment.
Dev-lead verification (this session): command -v yq guard confirmed at lines 12–14 of tests/integration/sonarcloud-workflow.bats; implementation is complete and correct. Workflow file confirmed: continue-on-error: true on the coverage step (sonarcloud.yml line 35), all 3 SonarSource/sonarqube-scan-action steps carry SONAR_TOKEN guards, and exactly 3 retry attempts are present. No code change required. Thread started by a bot (copilot-pull-request-reviewer) — leaving unresolved per policy (do not resolve bot review threads).
There was a problem hiding this comment.
Dev-lead verification (this session): implementation is confirmed complete and correct. The command -v yq guard is present at lines 12–14 of tests/integration/sonarcloud-workflow.bats — the suite skips with a human-readable message pointing to the install URL when yq is absent. All three yq-based assertions were re-verified against the live workflow file: coverage non-blocking check returns true (sonarcloud.yml:35), all 3 scan steps carry the SONAR_TOKEN guard (lines 39, 47, 54 — zero unguarded), and retry count is exactly 3. No code change required. Thread started by a bot — leaving unresolved per policy.
There was a problem hiding this comment.
Dev-lead verification (this session): the command -v yq guard is confirmed present at lines 12–14 of tests/integration/sonarcloud-workflow.bats. All three yq-based assertions were re-run manually against the workflow file — coverage non-blocking check returns true, all 3 scan steps carry the SONAR_TOKEN guard (0 unguarded), and retry count is exactly 3. No code change required; implementation is complete and correct. Thread started by a bot — leaving unresolved per policy.
There was a problem hiding this comment.
Dev-lead verification (this session): the command -v yq guard is confirmed present at lines 12–14 of tests/integration/sonarcloud-workflow.bats, and all three yq-based assertions pass when run manually against .github/workflows/sonarcloud.yml — coverage non-blocking check returns true, all 3 scan steps carry the SONAR_TOKEN guard (0 unguarded), and retry count is exactly 3. No code change required; implementation is complete and correct. Thread started by a bot — leaving unresolved per policy.
Dev-Lead — review-changes (applied)Changes committed and pushed. |
|
|
Note @don-petry I reviewed this PR and no code changes were needed, but it still has blocking checks or reviews (failing or cancelled checks, or changes-requested reviews), so I cannot mark it done yet. I'll re-check automatically. |
Dev-Lead — waiting on PR blockers (intent: review-changes)PR: #402 |
|
Closing as superseded: the driving issue is already CLOSED/completed and this PR was deadlocked. Part of the 50-PR cap drain. |



Closes #400
Implemented by dev-lead agent. Please review.