Browse Source

Remove superfluous role_name arguments

This patch removes the role_name when using openstack_user's :create
action (it gets ignored by the target method).

Note that the spec test would still pass if only the line in
identity_registration.rb (but not the test) were changed, because the
code that actually does grant the role to the resource is executed right
after user creation and before any tests check the resource for the
existence of the role_name attribute. In other words: if the argument
were required in a call but only supplied in another call, the spec
tests would not catch it. Something to watch out for.

Change-Id: I45754d269598b821f0b86b6257556ebfe74dcd6b
changes/74/519374/1
Roger Luethi 1 year ago
parent
commit
9ad24ffd47
2 changed files with 0 additions and 2 deletions
  1. 0
    1
      recipes/identity_registration.rb
  2. 0
    1
      spec/identity_registration_spec.rb

+ 0
- 1
recipes/identity_registration.rb View File

@@ -90,7 +90,6 @@ connection_params = {
90 90
   # Register Service User
91 91
   openstack_user service_user do
92 92
     project_name service_tenant_name
93
-    role_name service_role
94 93
     password service_pass
95 94
     connection_params connection_params
96 95
   end

+ 0
- 1
spec/identity_registration_spec.rb View File

@@ -76,7 +76,6 @@ describe 'openstack-telemetry::identity_registration' do
76 76
           service_user
77 77
         ).with(
78 78
           project_name: project_name,
79
-          role_name: role_name,
80 79
           password: password,
81 80
           connection_params: connection_params
82 81
         )

Loading…
Cancel
Save