@@ -50,20 +50,20 @@ os::cmd::expect_failure_and_text 'oc policy add-role-to-user' 'you must specify
50
50
os::cmd::expect_failure_and_text ' oc policy add-role-to-user -z NamespaceWithoutRole' ' you must specify a role'
51
51
os::cmd::expect_failure_and_text ' oc policy add-role-to-user view' ' you must specify at least one user or service account'
52
52
53
- os::cmd::expect_success_and_text ' oc policy add-role-to-group cluster-admin system:unauthenticated' ' role "cluster-admin" added: "system:unauthenticated"'
54
- os::cmd::expect_success_and_text ' oc policy add-role-to-user cluster-admin system:no-user' ' role "cluster-admin" added: "system:no-user"'
53
+ os::cmd::expect_success_and_text ' oc policy add-role-to-group cluster-admin --rolebinding-name cluster-admin system:unauthenticated' ' role "cluster-admin" added: "system:unauthenticated"'
54
+ os::cmd::expect_success_and_text ' oc policy add-role-to-user --rolebinding-name cluster-admin cluster-admin system:no-user' ' role "cluster-admin" added: "system:no-user"'
55
55
os::cmd::expect_success ' oc get rolebinding/cluster-admin --no-headers'
56
56
os::cmd::expect_success_and_text ' oc get rolebinding/cluster-admin --no-headers' ' system:no-user'
57
57
58
- os::cmd::expect_success_and_text ' oc policy add-role-to-user cluster-admin -z=one,two --serviceaccount=three,four' ' role "cluster-admin" added: \["one" "two" "three" "four"\]'
58
+ os::cmd::expect_success_and_text ' oc policy add-role-to-user --rolebinding-name cluster-admin cluster-admin -z=one,two --serviceaccount=three,four' ' role "cluster-admin" added: \["one" "two" "three" "four"\]'
59
59
os::cmd::expect_success ' oc get rolebinding/cluster-admin --no-headers'
60
60
os::cmd::expect_success_and_text ' oc get rolebinding/cluster-admin --no-headers' ' one'
61
61
os::cmd::expect_success_and_text ' oc get rolebinding/cluster-admin --no-headers' ' four'
62
62
63
- os::cmd::expect_success_and_text ' oc policy remove-role-from-group cluster-admin system:unauthenticated' ' role "cluster-admin" removed: "system:unauthenticated"'
63
+ os::cmd::expect_success_and_text ' oc policy remove-role-from-group --rolebinding-name cluster-admin cluster-admin system:unauthenticated' ' role "cluster-admin" removed: "system:unauthenticated"'
64
64
65
- os::cmd::expect_success_and_text ' oc policy remove-role-from-user cluster-admin system:no-user' ' role "cluster-admin" removed: "system:no-user"'
66
- os::cmd::expect_success_and_text ' oc policy remove-role-from-user cluster-admin -z=one,two --serviceaccount=three,four' ' role "cluster-admin" removed: \["one" "two" "three" "four"\]'
65
+ os::cmd::expect_success_and_text ' oc policy remove-role-from-user --rolebinding-name cluster-admin cluster-admin system:no-user' ' role "cluster-admin" removed: "system:no-user"'
66
+ os::cmd::expect_success_and_text ' oc policy remove-role-from-user --rolebinding-name cluster-admin cluster-admin -z=one,two --serviceaccount=three,four' ' role "cluster-admin" removed: \["one" "two" "three" "four"\]'
67
67
os::cmd::expect_success ' oc get rolebinding/cluster-admin --no-headers'
68
68
os::cmd::expect_success_and_not_text ' oc get rolebinding/cluster-admin --no-headers' ' four'
69
69
0 commit comments