-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sync to 2 different DAB team member roles #2241
Merged
Merged
Conversation
This file contains 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
github-actions
bot
added
backport-4.2
This PR should be backported to stable-4.2 (1.2)
backport-4.4
This PR should be backported to stable-4.4 (2.1)
backport-4.5
This PR should be backported to stable-4.5 (2.2)
backport-4.6
This PR should be backported to stable-4.6 (2.3)
backport-4.7
This PR should be backported to stable-4.7 (2.4)
backport-4.8
This PR should be backported to stable-4.8 (2.4)
backport-4.9
This PR should be backported to stable-4.9 (2.4)
labels
Aug 22, 2024
AlanCoding
force-pushed
the
cowboy_roles
branch
from
August 22, 2024 03:15
a748bcb
to
e37f372
Compare
jctanner
removed
backport-4.2
This PR should be backported to stable-4.2 (1.2)
backport-4.4
This PR should be backported to stable-4.4 (2.1)
backport-4.5
This PR should be backported to stable-4.5 (2.2)
backport-4.6
This PR should be backported to stable-4.6 (2.3)
backport-4.7
This PR should be backported to stable-4.7 (2.4)
backport-4.8
This PR should be backported to stable-4.8 (2.4)
backport-4.9
This PR should be backported to stable-4.9 (2.4)
labels
Aug 22, 2024
AlanCoding
force-pushed
the
cowboy_roles
branch
from
August 22, 2024 15:39
5a856c5
to
cd8aba8
Compare
AlanCoding
force-pushed
the
cowboy_roles
branch
from
August 22, 2024 15:41
cd8aba8
to
0e2d2c3
Compare
I got 1 failure from this check
|
AlanCoding
force-pushed
the
cowboy_roles
branch
from
August 22, 2024 16:53
0e2d2c3
to
e9f6b2a
Compare
now I'm getting this
|
Log and ignore removing users that can not be removed Issue: AAH-3358
AlanCoding
force-pushed
the
cowboy_roles
branch
from
August 22, 2024 17:23
e9f6b2a
to
f99bbbf
Compare
jctanner
approved these changes
Aug 22, 2024
Documenting a hypothetical test for the 2nd script mentioned above: def test_group_sync_from_pulp_to_dab_via_group(galaxy_client, assert_user_in_group, user_and_group):
"The group users relationship is the reverse of the user groups relationship"
gc = galaxy_client("admin")
user, group = user_and_group
assert_user_in_group(user["id"], group["id"], expected=False)
old_users = group["users"].copy()
group["users"].append(user)
gc.patch(f"_ui/v2/groups/{group['id']}/", body={"users": group["users"]})
assert_user_in_group(user["id"], group["id"], expected=True)
gc.patch(f"_ui/v2/groups/{group['id']}/", body={"users": old_users})
assert_user_in_group(user["id"], group["id"], expected=False) This does not work because the group-detail endpoint does not actually take in users as a field. So this can not be done via the API in integration tests. And current tests are taken as sufficient. |
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.
What is this PR doing:
Testing for this is problematic. I will share my hacked tests for this. The first blurb is the one that really can't be tested by other means.
This test could maybe be an integration test.
Issue: AAH-3358
requires ansible/django-ansible-base#562
Reviewers must know:
To run this I had to install from:
Then I commented out the skip on
test_team_member_sync_from_dab_to_pulp
, and that was passing. So more of the testing from this could/should be absorbed into that.The "Team Member" role, however, will be set by jwt_consumer, and there is no way to test that other than hacking.