Swap id field in grants to ids since that's now standardized (#4250)

* Swap id field in grants to ids since that's now standardized

* Fix some tests I missed

* Update generated resource table
This commit is contained in:
Jeff Mitchell authored and GitHub committed 2024-01-17 23:54:49 -08:00
1 parent 962f9bd638
commit 253d79116c
43 files changed
+392 -392

No files matched your search

@@ -84,25 +84,25 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on global, no groups",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
recurseFrom: "global",
},
{
name: "perms on org, no groups",
orgGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
orgGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
recurseFrom: "org",
},
{
name: "perms on project, no groups",
projGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=list,no-op"},
recurseFrom: "project",
},
{
name: "perms on global, none in org",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -111,8 +111,8 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on global, none in org, start at org",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -121,9 +121,9 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on global, with org",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
orgGrants: []string{"id=*;type=group;actions=read"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
orgGrants: []string{"ids=*;type=group;actions=read"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -132,9 +132,9 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on global, with org, start at org",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
orgGrants: []string{"id=*;type=group;actions=read"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
orgGrants: []string{"ids=*;type=group;actions=read"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -143,9 +143,9 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on global, start at project",
globalGrants: []string{"id=*;type=group;actions=list,no-op"},
orgGrants: []string{"id=*;type=group;actions=read"},
projGrants: []string{"id=*;type=group;actions=read"},
globalGrants: []string{"ids=*;type=group;actions=list,no-op"},
orgGrants: []string{"ids=*;type=group;actions=read"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -154,8 +154,8 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on org, start at global, no read on org",
orgGrants: []string{"id=*;type=group;actions=list"},
projGrants: []string{"id=*;type=group;actions=read"},
orgGrants: []string{"ids=*;type=group;actions=list"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -164,8 +164,8 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on org, start at global, read on org",
orgGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
orgGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -174,8 +174,8 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on org, start at org",
orgGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
orgGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -184,8 +184,8 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on org, start at project",
orgGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"id=*;type=group;actions=read"},
orgGrants: []string{"ids=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=read"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -194,7 +194,7 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on proj",
projGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=list,no-op"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -203,7 +203,7 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on proj, start at org",
projGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=list,no-op"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,
@@ -212,7 +212,7 @@ func TestListingScopeIds(t *testing.T) {
},
{
name: "perms on proj, start at global",
projGrants: []string{"id=*;type=group;actions=list,no-op"},
projGrants: []string{"ids=*;type=group;actions=list,no-op"},
globalGroups: 1,
orgGroups: 3,
projGroups: 5,