Skip to content
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

[4458] - Restrict non admins to partner users #4468

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

napster235
Copy link
Contributor

Resolves #4458

Description

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Specs were added

Screenshots

@@ -31,6 +42,8 @@

context "with valid user params" do
it "invites a new user and redirects back with notice" do
user.add_role(:org_admin)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you move this to a before(:each) block?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed it here 129a2b8


context "when user is not authorized" do
it "does not have access to index template" do
user.add_role(:org_user)
Copy link
Collaborator

Choose a reason for hiding this comment

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

This gets added automatically, you don't need to do it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed it here 129a2b8

@@ -72,6 +73,8 @@
end

it "redirects back with alert if the user role removal fails" do
user.add_role(:org_admin)
Copy link
Collaborator

Choose a reason for hiding this comment

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

This line shouldn't be necessary since it's in a beforeblock, no?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right. I think I missed this one. Fixed it here f0ab010

@dorner
Copy link
Collaborator

dorner commented Jul 3, 2024

Looks like there are failing tests now.

@dorner
Copy link
Collaborator

dorner commented Aug 16, 2024

@napster235 will you be able to fix the tests?

@napster235
Copy link
Contributor Author

not any time soon i'm afraid

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Restrict partner-user-management to bank org admins
2 participants