@@ -17,6 +17,12 @@ import (
1717)
1818
1919const (
20+ // Account scope.
21+ AccountScope string = "account"
22+
23+ // Account/Project member.
24+ Member string = "member"
25+
2026 groupsURL = "iam/v1/groups"
2127 groupsIDURL = "iam/v1/groups/123"
2228 rolesURL = "iam/v1/groups/123/roles"
@@ -45,7 +51,7 @@ func TestList(t *testing.T) {
4551 Name : "test_name" ,
4652 Description : "test_description" ,
4753 Roles : []roles.Role {
48- {Scope : roles . Account , RoleName : roles . Member },
54+ {Scope : AccountScope , RoleName : Member },
4955 },
5056 },
5157 }},
@@ -120,7 +126,7 @@ func TestGet(t *testing.T) {
120126 Name : "test_name" ,
121127 Description : "test_description" ,
122128 Roles : []roles.Role {
123- {Scope : roles . Account , RoleName : roles . Member },
129+ {Scope : AccountScope , RoleName : Member },
124130 },
125131 },
126132 ServiceUsers : []ServiceUser {
@@ -432,7 +438,7 @@ func TestAssignRoles(t *testing.T) {
432438 args : args {
433439 groupID : "123" ,
434440 roles : []roles.Role {
435- {Scope : roles . Account , RoleName : roles . Member },
441+ {Scope : AccountScope , RoleName : Member },
436442 },
437443 },
438444 prepare : func () {
@@ -449,7 +455,7 @@ func TestAssignRoles(t *testing.T) {
449455 args : args {
450456 groupID : "123" ,
451457 roles : []roles.Role {
452- {Scope : roles . Account , RoleName : roles . Member },
458+ {Scope : AccountScope , RoleName : Member },
453459 },
454460 },
455461 prepare : func () {
@@ -502,7 +508,7 @@ func TestUnassignRoles(t *testing.T) {
502508 args : args {
503509 groupID : "123" ,
504510 roles : []roles.Role {
505- {Scope : roles . Account , RoleName : roles . Member },
511+ {Scope : AccountScope , RoleName : Member },
506512 },
507513 },
508514 prepare : func () {
@@ -519,7 +525,7 @@ func TestUnassignRoles(t *testing.T) {
519525 args : args {
520526 groupID : "123" ,
521527 roles : []roles.Role {
522- {Scope : roles . Account , RoleName : roles . Member },
528+ {Scope : AccountScope , RoleName : Member },
523529 },
524530 },
525531 prepare : func () {
0 commit comments