File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed
app/controllers/organizations/onboarding
test/functional/organizations/onboarding Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def available_rubygems
2828 helper_method :available_rubygems
2929
3030 def approved_invites
31- owner = OrganizationInvite . new ( user : @organization_onboarding . created_by , role : :admin )
31+ owner = OrganizationInvite . new ( user : @organization_onboarding . created_by , role : :owner )
3232 @approved_invites ||= @organization_onboarding . approved_invites . prepend ( owner )
3333 end
3434 helper_method :approved_invites
Original file line number Diff line number Diff line change @@ -37,6 +37,16 @@ class Organizations::Onboarding::UsersControllerTest < ActionDispatch::Integrati
3737 end
3838
3939 context "on GET /organizations/onboarding/users" do
40+ should "show the creator with Owner role in approved invites" do
41+ get organization_onboarding_users_path ( as : @user )
42+
43+ assert_response :ok
44+
45+ creator_invite = @controller . view_assigns [ "approved_invites" ] . find { |i | i . user == @user }
46+
47+ assert_equal "owner" , creator_invite . role
48+ end
49+
4050 should "render the list of users to invite" do
4151 get organization_onboarding_users_path ( as : @user )
4252
You can’t perform that action at this time.
0 commit comments