Documentation ¶
Overview ¶
Package auth is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CountryPermissions ¶
type CountryPermissions map[string]containers.Set[Permission]
type Interface ¶
type Interface interface { IsGlobalAdmin() bool GetAllowedCountries() containers.StringSet HasCountryLevelPermission(countryID string, perm Permission) bool HasCountryPermissionWrite(countryID string) bool HasCountryPermissionRead(countryID string) bool }
func New ¶
func New(countryPermissions CountryPermissions, allCountryIDs containers.StringSet, isGlobalAdmin bool) Interface
type MockInterface ¶
type MockInterface struct {
// contains filtered or unexported fields
}
MockInterface is a mock of Interface interface.
func NewMockInterface ¶
func NewMockInterface(ctrl *gomock.Controller) *MockInterface
NewMockInterface creates a new mock instance.
func (*MockInterface) CanReadWriteToCountryID ¶
func (m *MockInterface) CanReadWriteToCountryID(arg0 string) bool
CanReadWriteToCountryID mocks base method.
func (*MockInterface) EXPECT ¶
func (m *MockInterface) EXPECT() *MockInterfaceMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockInterface) GetAllowedCountries ¶
func (m *MockInterface) GetAllowedCountries() containers.Set[string]
GetAllowedCountries mocks base method.
func (*MockInterface) IsGlobalAdmin ¶
func (m *MockInterface) IsGlobalAdmin() bool
IsGlobalAdmin mocks base method.
type MockInterfaceMockRecorder ¶
type MockInterfaceMockRecorder struct {
// contains filtered or unexported fields
}
MockInterfaceMockRecorder is the mock recorder for MockInterface.
func (*MockInterfaceMockRecorder) CanReadWriteToCountryID ¶
func (mr *MockInterfaceMockRecorder) CanReadWriteToCountryID(arg0 interface{}) *gomock.Call
CanReadWriteToCountryID indicates an expected call of CanReadWriteToCountryID.
func (*MockInterfaceMockRecorder) GetAllowedCountries ¶
func (mr *MockInterfaceMockRecorder) GetAllowedCountries() *gomock.Call
GetAllowedCountries indicates an expected call of GetAllowedCountries.
func (*MockInterfaceMockRecorder) IsGlobalAdmin ¶
func (mr *MockInterfaceMockRecorder) IsGlobalAdmin() *gomock.Call
IsGlobalAdmin indicates an expected call of IsGlobalAdmin.
type Permission ¶
type Permission uint8
const ( PermissionGlobalAdmin Permission = iota PermissionWrite PermissionRead )
Click to show internal directories.
Click to hide internal directories.