Documentation ¶
Index ¶
- func NewRBACProviderMock() accesscontrol.RBACProvider
- func ReaderFromAny(v any) io.Reader
- type RBACMock
- func (r *RBACMock) AllowRole(role string, object string, action []accesscontrol.Action) error
- func (r *RBACMock) AllowRoleInProject(project, role string, object string, action []accesscontrol.Action) error
- func (r RBACMock) GetAllMembersOfOrganization() ([]string, error)
- func (r RBACMock) GetAllMembersOfProject(project string) ([]string, error)
- func (r RBACMock) GetAllProjectsForUser(user string) []string
- func (r *RBACMock) GetAllRoles(user string) []string
- func (r RBACMock) GetDomainRole(domain string) (string, error)
- func (r *RBACMock) GetOwnerOfOrganization() (string, error)
- func (r RBACMock) GetProjectRole(domain, project string) (string, error)
- func (r *RBACMock) GetProjectRoleName(project string, role string) string
- func (r *RBACMock) GrantRole(subject, role string) error
- func (r *RBACMock) GrantRoleInProject(subject string, role string, project string) error
- func (r *RBACMock) HasAccess(subject string) bool
- func (r *RBACMock) InheritProjectRole(roleWhichGetsPermissions, roleWhichProvidesPermissions, project string) error
- func (r RBACMock) InheritProjectRolesAcrossProjects(...) error
- func (r *RBACMock) InheritRole(roleWhichGetsPermissions, roleWhichProvidesPermissions string) error
- func (r *RBACMock) IsAllowed(subject, object string, action accesscontrol.Action) (bool, error)
- func (r *RBACMock) IsAllowedInProject(project, user, object string, action accesscontrol.Action) (bool, error)
- func (r *RBACMock) LinkDomainAndProjectRole(...) error
- func (r *RBACMock) RevokeRole(subject string, role string) error
- func (r *RBACMock) RevokeRoleInProject(subject string, role string, project string) error
- type RBACProviderMock
- type SessionMock
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRBACProviderMock ¶
func NewRBACProviderMock() accesscontrol.RBACProvider
func ReaderFromAny ¶
Types ¶
type RBACMock ¶
type RBACMock struct {
// contains filtered or unexported fields
}
func (*RBACMock) AllowRoleInProject ¶
func (RBACMock) GetAllMembersOfOrganization ¶ added in v0.4.19
func (RBACMock) GetAllMembersOfProject ¶ added in v0.5.14
func (RBACMock) GetAllProjectsForUser ¶
func (*RBACMock) GetAllRoles ¶
func (RBACMock) GetDomainRole ¶ added in v0.5.14
func (*RBACMock) GetOwnerOfOrganization ¶
func (RBACMock) GetProjectRole ¶ added in v0.5.14
func (*RBACMock) GetProjectRoleName ¶
func (*RBACMock) GrantRoleInProject ¶
func (*RBACMock) InheritProjectRole ¶
func (RBACMock) InheritProjectRolesAcrossProjects ¶ added in v0.5.15
func (r RBACMock) InheritProjectRolesAcrossProjects(roleWhichGetsPermissions, roleWhichProvidesPermissions accesscontrol.ProjectRole) error
func (*RBACMock) InheritRole ¶
func (*RBACMock) IsAllowedInProject ¶
func (*RBACMock) LinkDomainAndProjectRole ¶
type RBACProviderMock ¶
type RBACProviderMock struct { }
func (RBACProviderMock) DomainsOfUser ¶
func (r RBACProviderMock) DomainsOfUser(user string) ([]string, error)
func (RBACProviderMock) GetDomainRBAC ¶
func (r RBACProviderMock) GetDomainRBAC(domain string) accesscontrol.AccessControl
type SessionMock ¶
type SessionMock struct {
UserID string
}
func NewSessionMock ¶
func NewSessionMock(userID string) SessionMock
func (SessionMock) GetUserID ¶
func (s SessionMock) GetUserID() string
Click to show internal directories.
Click to hide internal directories.