Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 3 Skipped Deployments
|
Contributor
Docker builds report
|
Contributor
Playwright Test Results (oss - depot-ubuntu-latest-16)Details
|
Contributor
Playwright Test Results (oss - depot-ubuntu-latest-arm-16)Details
|
Contributor
Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)Details
|
Contributor
Playwright Test Results (private-cloud - depot-ubuntu-latest-16)Details
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6848 +/- ##
=======================================
Coverage 98.33% 98.33%
=======================================
Files 1336 1336
Lines 49615 49615
=======================================
Hits 48790 48790
Misses 825 825 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
emyller
reviewed
Mar 4, 2026
api/tests/unit/environments/identities/test_unit_identities_views.py
Outdated
Show resolved
Hide resolved
emyller
approved these changes
Mar 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Fixes 2 flaky unit tests:
test_get_feature_states_for_identity- this test failed when the multivariate feature values were returned in reverse order since the test assumed they were returned in the order they were created.test_identities_endpoint_returns_value_for_segment_if_rule_type_percentage_split_and_identity_in_segment- this test failed if the returned value fromget_hashed_percentage_valuewas between 0.99 and 0.995. The maths when creating the Condition then meant that the percentage value was 99, and hence the user was deemed outside of the segment. Since the logic for actually determining segment membership is covered elsewhere, I just set the percentage to 100 to guarantee that the identity will be in the segment.How did you test this code?
Ran the tests 100 times consecutively (using
pytest.mark.parametrise) to verify that the tests consistently passed.