Commit aff5a71
fix: Add CustomDynamicSamplingRule back to user merge test coverage
The CustomDynamicSamplingRule model has RelocationScope.Organization and a
HybridCloudForeignKey to User via created_by_id. It was removed from the
@expect_models decorators and model_list, but the model still exists and needs
to be included in user merge coverage to pass the
test_all_eligible_organization_scoped_models_tested_for_user_merge test.
This fix:
1. Adds CustomDynamicSamplingRule import and includes it in both @expect_models
decorators in test_user.py
2. Sets created_by_id=owner_id when creating CustomDynamicSamplingRule in
create_exhaustive_organization fixture
3. Adds CustomDynamicSamplingRule to model_list in organization impl.py for
user merging
Co-authored-by: Armen Zambrano G. <armenzg@users.noreply.github.com>1 parent c4c7084 commit aff5a71
3 files changed
Lines changed: 6 additions & 0 deletions
File tree
- src/sentry
- organizations/services/organization
- testutils/helpers
- tests/sentry/users/models
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| |||
580 | 581 | | |
581 | 582 | | |
582 | 583 | | |
| 584 | + | |
583 | 585 | | |
584 | 586 | | |
585 | 587 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
826 | 826 | | |
827 | 827 | | |
828 | 828 | | |
| 829 | + | |
829 | 830 | | |
830 | 831 | | |
831 | 832 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
382 | 383 | | |
383 | 384 | | |
384 | 385 | | |
| 386 | + | |
385 | 387 | | |
386 | 388 | | |
387 | 389 | | |
| |||
425 | 427 | | |
426 | 428 | | |
427 | 429 | | |
| 430 | + | |
428 | 431 | | |
429 | 432 | | |
430 | 433 | | |
| |||
0 commit comments