Skip to content

fix: update permission test query counts for RBAC#6547

Merged
gagantrivedi merged 1 commit intomainfrom
fix/perm-tests-with-rbac
Jan 19, 2026
Merged

fix: update permission test query counts for RBAC#6547
gagantrivedi merged 1 commit intomainfrom
fix/perm-tests-with-rbac

Conversation

@gagantrivedi
Copy link
Copy Markdown
Member

Thanks for submitting a PR! Please check the boxes below:

  • I have read the Contributing Guide.
  • I have added information to docs/ if required so people know about the feature.
  • I have filled in the "Changes" section below.
  • I have filled in the "How did you test this code" section below.

Changes

Follows up on #6537

Updates expected query counts in permission tests to account for the additional RBAC role permission check when IS_RBAC_INSTALLED is True.

  • test_is_user_environment_admin__short_circuits_on_direct_permission: 6 → 7 queries with RBAC
  • test_is_user_environment_admin__short_circuits_on_group_permission: 7 → 8 queries with RBAC
  • test_view_environment_with_staff__query_count_is_expected_with_rbac: 12 → 13 queries

How did you test this code?

Ran the affected tests with RBAC enabled in CI.

Update expected query counts in permission tests to account for
the additional RBAC role permission check when IS_RBAC_INSTALLED
is True.
@gagantrivedi gagantrivedi requested a review from a team as a code owner January 19, 2026 09:37
@vercel
Copy link
Copy Markdown

vercel Bot commented Jan 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

3 Skipped Deployments
Project Deployment Review Updated (UTC)
docs Ignored Ignored Jan 19, 2026 9:37am
flagsmith-frontend-preview Ignored Ignored Jan 19, 2026 9:37am
flagsmith-frontend-staging Ignored Ignored Jan 19, 2026 9:37am

Request Review

@gagantrivedi gagantrivedi requested review from khvn26 and removed request for a team January 19, 2026 09:37
@github-actions github-actions Bot added api Issue related to the REST API fix labels Jan 19, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jan 19, 2026

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-e2e:pr-6547 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-api-test:pr-6547 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-frontend:pr-6547 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-api:pr-6547 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-private-cloud:pr-6547 Finished ✅ Results
ghcr.io/flagsmith/flagsmith:pr-6547 Finished ✅ Results

@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 19, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.09%. Comparing base (04df8d5) to head (7001e35).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6547   +/-   ##
=======================================
  Coverage   98.09%   98.09%           
=======================================
  Files        1293     1293           
  Lines       46607    46610    +3     
=======================================
+ Hits        45719    45722    +3     
  Misses        888      888           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown
Contributor

@Zaimwa9 Zaimwa9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I remember having seen something already 🤔

@gagantrivedi gagantrivedi merged commit e2e77b0 into main Jan 19, 2026
45 of 46 checks passed
@gagantrivedi gagantrivedi deleted the fix/perm-tests-with-rbac branch January 19, 2026 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api Issue related to the REST API fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants