@@ -811,17 +811,18 @@ func TestTemplateACL(t *testing.T) {
811
811
t .Run ("DisableEveryoneGroupAccess" , func (t * testing.T ) {
812
812
t .Parallel ()
813
813
814
- client , user := coderdenttest .New (t , & coderdenttest.Options {LicenseOptions : & coderdenttest.LicenseOptions {
814
+ client , admin := coderdenttest .New (t , & coderdenttest.Options {LicenseOptions : & coderdenttest.LicenseOptions {
815
815
Features : license.Features {
816
816
codersdk .FeatureTemplateRBAC : 1 ,
817
817
},
818
818
}})
819
- version := coderdtest .CreateTemplateVersion (t , client , user .OrganizationID , nil )
820
- template := coderdtest .CreateTemplate (t , client , user .OrganizationID , version .ID )
819
+ version := coderdtest .CreateTemplateVersion (t , client , admin .OrganizationID , nil )
820
+ template := coderdtest .CreateTemplate (t , client , admin .OrganizationID , version .ID )
821
821
822
822
ctx , cancel := context .WithTimeout (context .Background (), testutil .WaitLong )
823
823
defer cancel ()
824
824
825
+ //nolint:gocritic // non-template-admin cannot get template acl
825
826
acl , err := client .TemplateACL (ctx , template .ID )
826
827
require .NoError (t , err )
827
828
require .Equal (t , 1 , len (acl .Groups ))
0 commit comments