Documentation
¶
Index ¶
- type AccessTokenFixture
- func (f *AccessTokenFixture) AccountID(accountID uuid.UUID) *AccessTokenFixture
- func (f *AccessTokenFixture) Cleanup(tb testing.TB) *AccessTokenFixture
- func (f *AccessTokenFixture) Create(tb testing.TB) *AccessTokenFixture
- func (f *AccessTokenFixture) CreatedAt(createdAt time.Time) *AccessTokenFixture
- func (f *AccessTokenFixture) Data(data []byte) *AccessTokenFixture
- func (f *AccessTokenFixture) ExpiresAt(expiresAt time.Time) *AccessTokenFixture
- func (f *AccessTokenFixture) GetEntity() storage.AccessToken
- func (f *AccessTokenFixture) Hash(hash string) *AccessTokenFixture
- func (f *AccessTokenFixture) IdentityID(identityID uuid.UUID) *AccessTokenFixture
- func (f *AccessTokenFixture) PullUpdates(tb testing.TB) *AccessTokenFixture
- func (f *AccessTokenFixture) PushUpdates(tb testing.TB) *AccessTokenFixture
- func (f *AccessTokenFixture) RevokedAt(revokedAt null.Time) *AccessTokenFixture
- func (f *AccessTokenFixture) Roles(roles []string) *AccessTokenFixture
- func (f *AccessTokenFixture) SessionID(sessionID uuid.UUID) *AccessTokenFixture
- type AccountFixture
- func (f *AccountFixture) Cleanup(tb testing.TB) *AccountFixture
- func (f *AccountFixture) Create(tb testing.TB) *AccountFixture
- func (f *AccountFixture) CreatedAt(createdAt time.Time) *AccountFixture
- func (f *AccountFixture) Data(data []byte) *AccountFixture
- func (f *AccountFixture) GetEntity() storage.Account
- func (f *AccountFixture) ID(iD uuid.UUID) *AccountFixture
- func (f *AccountFixture) PullUpdates(tb testing.TB) *AccountFixture
- func (f *AccountFixture) PushUpdates(tb testing.TB) *AccountFixture
- func (f *AccountFixture) Roles(roles []string) *AccountFixture
- func (f *AccountFixture) Status(status storage.AccountStatus) *AccountFixture
- func (f *AccountFixture) UpdatedAt(updatedAt time.Time) *AccountFixture
- type CredentialFixture
- func (f *CredentialFixture) AccountID(accountID uuid.UUID) *CredentialFixture
- func (f *CredentialFixture) Cleanup(tb testing.TB) *CredentialFixture
- func (f *CredentialFixture) CleanupAllOfAccount(tb testing.TB) *CredentialFixture
- func (f *CredentialFixture) Create(tb testing.TB) *CredentialFixture
- func (f *CredentialFixture) CreatedAt(createdAt time.Time) *CredentialFixture
- func (f *CredentialFixture) ExpiredAt(expiredAt null.Time) *CredentialFixture
- func (f *CredentialFixture) GetEntity() storage.Credential
- func (f *CredentialFixture) Hash(hash string) *CredentialFixture
- func (f *CredentialFixture) PullUpdates(tb testing.TB) *CredentialFixture
- func (f *CredentialFixture) PushUpdates(tb testing.TB) *CredentialFixture
- func (f *CredentialFixture) Type(typ string) *CredentialFixture
- type FixturesFactory
- func (f *FixturesFactory) AccessToken() *AccessTokenFixture
- func (f *FixturesFactory) Account() *AccountFixture
- func (f *FixturesFactory) Credential() *CredentialFixture
- func (f *FixturesFactory) Identity() *IdentityFixture
- func (f *FixturesFactory) RefreshToken() *RefreshTokenFixture
- func (f *FixturesFactory) ResetPasswordRequest() *ResetPasswordRequestFixture
- func (f *FixturesFactory) Session() *SessionFixture
- type IdentityFixture
- func (f *IdentityFixture) AccountID(accountID uuid.UUID) *IdentityFixture
- func (f *IdentityFixture) Cleanup(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) CleanupAllOfAccount(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) Create(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) CreatedAt(createdAt time.Time) *IdentityFixture
- func (f *IdentityFixture) Data(data []byte) *IdentityFixture
- func (f *IdentityFixture) GetEntity() storage.Identity
- func (f *IdentityFixture) ID(iD uuid.UUID) *IdentityFixture
- func (f *IdentityFixture) Identity(identity string) *IdentityFixture
- func (f *IdentityFixture) PullUpdates(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) PullUpdatesLastAccountIdentity(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) PushUpdates(tb testing.TB) *IdentityFixture
- func (f *IdentityFixture) Status(status storage.IdentityStatus) *IdentityFixture
- func (f *IdentityFixture) Type(typ string) *IdentityFixture
- func (f *IdentityFixture) UpdatedAt(updatedAt time.Time) *IdentityFixture
- type RefreshTokenFixture
- func (f *RefreshTokenFixture) Cleanup(tb testing.TB) *RefreshTokenFixture
- func (f *RefreshTokenFixture) Create(tb testing.TB) *RefreshTokenFixture
- func (f *RefreshTokenFixture) CreatedAt(createdAt time.Time) *RefreshTokenFixture
- func (f *RefreshTokenFixture) ExpiresAt(expiresAt time.Time) *RefreshTokenFixture
- func (f *RefreshTokenFixture) GetEntity() storage.RefreshToken
- func (f *RefreshTokenFixture) Hash(hash string) *RefreshTokenFixture
- func (f *RefreshTokenFixture) IdentityID(identityID uuid.UUID) *RefreshTokenFixture
- func (f *RefreshTokenFixture) PullUpdates(tb testing.TB) *RefreshTokenFixture
- func (f *RefreshTokenFixture) PushUpdates(tb testing.TB) *RefreshTokenFixture
- func (f *RefreshTokenFixture) RevokedAt(revokedAt null.Time) *RefreshTokenFixture
- func (f *RefreshTokenFixture) SessionID(sessionID uuid.UUID) *RefreshTokenFixture
- type ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) AccountID(accountID uuid.UUID) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) Cleanup(tb testing.TB) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) Create(tb testing.TB) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) CreatedAt(createdAt time.Time) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) GetEntity() storage.ResetPasswordRequest
- func (f *ResetPasswordRequestFixture) ID(iD uuid.UUID) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) LastSendAt(lastSendAt null.Time) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) PullUpdates(tb testing.TB) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) PushUpdates(tb testing.TB) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) Status(status storage.ResetPasswordStatus) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) Token(token string) *ResetPasswordRequestFixture
- func (f *ResetPasswordRequestFixture) UsedAt(usedAt null.Time) *ResetPasswordRequestFixture
- type SessionFixture
- func (f *SessionFixture) AccountID(accountID uuid.UUID) *SessionFixture
- func (f *SessionFixture) Cleanup(tb testing.TB) *SessionFixture
- func (f *SessionFixture) Create(tb testing.TB) *SessionFixture
- func (f *SessionFixture) CreatedAt(createdAt time.Time) *SessionFixture
- func (f *SessionFixture) Data(data []byte) *SessionFixture
- func (f *SessionFixture) ExpiresAt(expiresAt time.Time) *SessionFixture
- func (f *SessionFixture) GetEntity() storage.Session
- func (f *SessionFixture) ID(iD uuid.UUID) *SessionFixture
- func (f *SessionFixture) IdentityID(identityID uuid.UUID) *SessionFixture
- func (f *SessionFixture) PullUpdates(tb testing.TB) *SessionFixture
- func (f *SessionFixture) PushUpdates(tb testing.TB) *SessionFixture
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessTokenFixture ¶
type AccessTokenFixture struct {
// contains filtered or unexported fields
}
func NewAccessTokenFixture ¶
func NewAccessTokenFixture(db storage.DBTX, defaultEntity storage.AccessToken) *AccessTokenFixture
func (*AccessTokenFixture) AccountID ¶
func (f *AccessTokenFixture) AccountID(accountID uuid.UUID) *AccessTokenFixture
func (*AccessTokenFixture) Cleanup ¶
func (f *AccessTokenFixture) Cleanup(tb testing.TB) *AccessTokenFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*AccessTokenFixture) Create ¶
func (f *AccessTokenFixture) Create(tb testing.TB) *AccessTokenFixture
func (*AccessTokenFixture) CreatedAt ¶
func (f *AccessTokenFixture) CreatedAt(createdAt time.Time) *AccessTokenFixture
func (*AccessTokenFixture) Data ¶
func (f *AccessTokenFixture) Data(data []byte) *AccessTokenFixture
func (*AccessTokenFixture) ExpiresAt ¶
func (f *AccessTokenFixture) ExpiresAt(expiresAt time.Time) *AccessTokenFixture
func (*AccessTokenFixture) GetEntity ¶
func (f *AccessTokenFixture) GetEntity() storage.AccessToken
func (*AccessTokenFixture) Hash ¶
func (f *AccessTokenFixture) Hash(hash string) *AccessTokenFixture
func (*AccessTokenFixture) IdentityID ¶
func (f *AccessTokenFixture) IdentityID(identityID uuid.UUID) *AccessTokenFixture
func (*AccessTokenFixture) PullUpdates ¶
func (f *AccessTokenFixture) PullUpdates(tb testing.TB) *AccessTokenFixture
func (*AccessTokenFixture) PushUpdates ¶
func (f *AccessTokenFixture) PushUpdates(tb testing.TB) *AccessTokenFixture
func (*AccessTokenFixture) RevokedAt ¶
func (f *AccessTokenFixture) RevokedAt(revokedAt null.Time) *AccessTokenFixture
func (*AccessTokenFixture) Roles ¶
func (f *AccessTokenFixture) Roles(roles []string) *AccessTokenFixture
func (*AccessTokenFixture) SessionID ¶
func (f *AccessTokenFixture) SessionID(sessionID uuid.UUID) *AccessTokenFixture
type AccountFixture ¶
type AccountFixture struct {
// contains filtered or unexported fields
}
func NewAccountFixture ¶
func NewAccountFixture(db storage.DBTX, defaultEntity storage.Account) *AccountFixture
func (*AccountFixture) Cleanup ¶
func (f *AccountFixture) Cleanup(tb testing.TB) *AccountFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*AccountFixture) Create ¶
func (f *AccountFixture) Create(tb testing.TB) *AccountFixture
func (*AccountFixture) CreatedAt ¶
func (f *AccountFixture) CreatedAt(createdAt time.Time) *AccountFixture
func (*AccountFixture) Data ¶
func (f *AccountFixture) Data(data []byte) *AccountFixture
func (*AccountFixture) GetEntity ¶
func (f *AccountFixture) GetEntity() storage.Account
func (*AccountFixture) ID ¶
func (f *AccountFixture) ID(iD uuid.UUID) *AccountFixture
func (*AccountFixture) PullUpdates ¶
func (f *AccountFixture) PullUpdates(tb testing.TB) *AccountFixture
func (*AccountFixture) PushUpdates ¶
func (f *AccountFixture) PushUpdates(tb testing.TB) *AccountFixture
func (*AccountFixture) Roles ¶
func (f *AccountFixture) Roles(roles []string) *AccountFixture
func (*AccountFixture) Status ¶
func (f *AccountFixture) Status(status storage.AccountStatus) *AccountFixture
func (*AccountFixture) UpdatedAt ¶
func (f *AccountFixture) UpdatedAt(updatedAt time.Time) *AccountFixture
type CredentialFixture ¶
type CredentialFixture struct {
// contains filtered or unexported fields
}
func NewCredentialFixture ¶
func NewCredentialFixture(db storage.DBTX, defaultEntity storage.Credential) *CredentialFixture
func (*CredentialFixture) AccountID ¶
func (f *CredentialFixture) AccountID(accountID uuid.UUID) *CredentialFixture
func (*CredentialFixture) Cleanup ¶
func (f *CredentialFixture) Cleanup(tb testing.TB) *CredentialFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*CredentialFixture) CleanupAllOfAccount ¶
func (f *CredentialFixture) CleanupAllOfAccount(tb testing.TB) *CredentialFixture
CleanupAllOfAccount calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete all records from the table by the IdentityID field.
func (*CredentialFixture) Create ¶
func (f *CredentialFixture) Create(tb testing.TB) *CredentialFixture
func (*CredentialFixture) CreatedAt ¶
func (f *CredentialFixture) CreatedAt(createdAt time.Time) *CredentialFixture
func (*CredentialFixture) ExpiredAt ¶
func (f *CredentialFixture) ExpiredAt(expiredAt null.Time) *CredentialFixture
func (*CredentialFixture) GetEntity ¶
func (f *CredentialFixture) GetEntity() storage.Credential
func (*CredentialFixture) Hash ¶
func (f *CredentialFixture) Hash(hash string) *CredentialFixture
func (*CredentialFixture) PullUpdates ¶
func (f *CredentialFixture) PullUpdates(tb testing.TB) *CredentialFixture
func (*CredentialFixture) PushUpdates ¶
func (f *CredentialFixture) PushUpdates(tb testing.TB) *CredentialFixture
func (*CredentialFixture) Type ¶
func (f *CredentialFixture) Type(typ string) *CredentialFixture
type FixturesFactory ¶
type FixturesFactory struct {
// contains filtered or unexported fields
}
func NewFixturesFactory ¶
func NewFixturesFactory(db storage.DBTX) *FixturesFactory
func (*FixturesFactory) AccessToken ¶
func (f *FixturesFactory) AccessToken() *AccessTokenFixture
func (*FixturesFactory) Account ¶
func (f *FixturesFactory) Account() *AccountFixture
func (*FixturesFactory) Credential ¶
func (f *FixturesFactory) Credential() *CredentialFixture
func (*FixturesFactory) Identity ¶
func (f *FixturesFactory) Identity() *IdentityFixture
func (*FixturesFactory) RefreshToken ¶
func (f *FixturesFactory) RefreshToken() *RefreshTokenFixture
func (*FixturesFactory) ResetPasswordRequest ¶
func (f *FixturesFactory) ResetPasswordRequest() *ResetPasswordRequestFixture
func (*FixturesFactory) Session ¶
func (f *FixturesFactory) Session() *SessionFixture
type IdentityFixture ¶
type IdentityFixture struct {
// contains filtered or unexported fields
}
func NewIdentityFixture ¶
func NewIdentityFixture(db storage.DBTX, defaultEntity storage.Identity) *IdentityFixture
func (*IdentityFixture) AccountID ¶
func (f *IdentityFixture) AccountID(accountID uuid.UUID) *IdentityFixture
func (*IdentityFixture) Cleanup ¶
func (f *IdentityFixture) Cleanup(tb testing.TB) *IdentityFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*IdentityFixture) CleanupAllOfAccount ¶
func (f *IdentityFixture) CleanupAllOfAccount(tb testing.TB) *IdentityFixture
CleanupAllOfAccount calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete all records from the table by the UserID field.
func (*IdentityFixture) Create ¶
func (f *IdentityFixture) Create(tb testing.TB) *IdentityFixture
func (*IdentityFixture) CreatedAt ¶
func (f *IdentityFixture) CreatedAt(createdAt time.Time) *IdentityFixture
func (*IdentityFixture) Data ¶
func (f *IdentityFixture) Data(data []byte) *IdentityFixture
func (*IdentityFixture) GetEntity ¶
func (f *IdentityFixture) GetEntity() storage.Identity
func (*IdentityFixture) ID ¶
func (f *IdentityFixture) ID(iD uuid.UUID) *IdentityFixture
func (*IdentityFixture) Identity ¶
func (f *IdentityFixture) Identity(identity string) *IdentityFixture
func (*IdentityFixture) PullUpdates ¶
func (f *IdentityFixture) PullUpdates(tb testing.TB) *IdentityFixture
func (*IdentityFixture) PullUpdatesLastAccountIdentity ¶
func (f *IdentityFixture) PullUpdatesLastAccountIdentity(tb testing.TB) *IdentityFixture
PullUpdatesLastAccountIdentity gets the last Identity of the account and updates the fixture entity. This method is useful when you need to get the data from the database after registering the account, when you don't have identity ID
func (*IdentityFixture) PushUpdates ¶
func (f *IdentityFixture) PushUpdates(tb testing.TB) *IdentityFixture
func (*IdentityFixture) Status ¶
func (f *IdentityFixture) Status(status storage.IdentityStatus) *IdentityFixture
func (*IdentityFixture) Type ¶
func (f *IdentityFixture) Type(typ string) *IdentityFixture
func (*IdentityFixture) UpdatedAt ¶
func (f *IdentityFixture) UpdatedAt(updatedAt time.Time) *IdentityFixture
type RefreshTokenFixture ¶
type RefreshTokenFixture struct {
// contains filtered or unexported fields
}
func NewRefreshTokenFixture ¶
func NewRefreshTokenFixture(db storage.DBTX, defaultEntity storage.RefreshToken) *RefreshTokenFixture
func (*RefreshTokenFixture) Cleanup ¶
func (f *RefreshTokenFixture) Cleanup(tb testing.TB) *RefreshTokenFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*RefreshTokenFixture) Create ¶
func (f *RefreshTokenFixture) Create(tb testing.TB) *RefreshTokenFixture
func (*RefreshTokenFixture) CreatedAt ¶
func (f *RefreshTokenFixture) CreatedAt(createdAt time.Time) *RefreshTokenFixture
func (*RefreshTokenFixture) ExpiresAt ¶
func (f *RefreshTokenFixture) ExpiresAt(expiresAt time.Time) *RefreshTokenFixture
func (*RefreshTokenFixture) GetEntity ¶
func (f *RefreshTokenFixture) GetEntity() storage.RefreshToken
func (*RefreshTokenFixture) Hash ¶
func (f *RefreshTokenFixture) Hash(hash string) *RefreshTokenFixture
func (*RefreshTokenFixture) IdentityID ¶
func (f *RefreshTokenFixture) IdentityID(identityID uuid.UUID) *RefreshTokenFixture
func (*RefreshTokenFixture) PullUpdates ¶
func (f *RefreshTokenFixture) PullUpdates(tb testing.TB) *RefreshTokenFixture
func (*RefreshTokenFixture) PushUpdates ¶
func (f *RefreshTokenFixture) PushUpdates(tb testing.TB) *RefreshTokenFixture
func (*RefreshTokenFixture) RevokedAt ¶
func (f *RefreshTokenFixture) RevokedAt(revokedAt null.Time) *RefreshTokenFixture
func (*RefreshTokenFixture) SessionID ¶
func (f *RefreshTokenFixture) SessionID(sessionID uuid.UUID) *RefreshTokenFixture
type ResetPasswordRequestFixture ¶
type ResetPasswordRequestFixture struct {
// contains filtered or unexported fields
}
func NewResetPasswordRequestFixture ¶
func NewResetPasswordRequestFixture(db storage.DBTX, defaultEntity storage.ResetPasswordRequest) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) AccountID ¶
func (f *ResetPasswordRequestFixture) AccountID(accountID uuid.UUID) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) Cleanup ¶
func (f *ResetPasswordRequestFixture) Cleanup(tb testing.TB) *ResetPasswordRequestFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*ResetPasswordRequestFixture) Create ¶
func (f *ResetPasswordRequestFixture) Create(tb testing.TB) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) CreatedAt ¶
func (f *ResetPasswordRequestFixture) CreatedAt(createdAt time.Time) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) GetEntity ¶
func (f *ResetPasswordRequestFixture) GetEntity() storage.ResetPasswordRequest
func (*ResetPasswordRequestFixture) ID ¶
func (f *ResetPasswordRequestFixture) ID(iD uuid.UUID) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) LastSendAt ¶
func (f *ResetPasswordRequestFixture) LastSendAt(lastSendAt null.Time) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) PullUpdates ¶
func (f *ResetPasswordRequestFixture) PullUpdates(tb testing.TB) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) PushUpdates ¶
func (f *ResetPasswordRequestFixture) PushUpdates(tb testing.TB) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) Status ¶
func (f *ResetPasswordRequestFixture) Status(status storage.ResetPasswordStatus) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) Token ¶
func (f *ResetPasswordRequestFixture) Token(token string) *ResetPasswordRequestFixture
func (*ResetPasswordRequestFixture) UsedAt ¶
func (f *ResetPasswordRequestFixture) UsedAt(usedAt null.Time) *ResetPasswordRequestFixture
type SessionFixture ¶
type SessionFixture struct {
// contains filtered or unexported fields
}
func NewSessionFixture ¶
func NewSessionFixture(db storage.DBTX, defaultEntity storage.Session) *SessionFixture
func (*SessionFixture) AccountID ¶
func (f *SessionFixture) AccountID(accountID uuid.UUID) *SessionFixture
func (*SessionFixture) Cleanup ¶
func (f *SessionFixture) Cleanup(tb testing.TB) *SessionFixture
Cleanup calls testing.TB.Cleanup() function with providing a callback inside it. This callback will delete a record from the table by primary key when test will be finished.
func (*SessionFixture) Create ¶
func (f *SessionFixture) Create(tb testing.TB) *SessionFixture
func (*SessionFixture) CreatedAt ¶
func (f *SessionFixture) CreatedAt(createdAt time.Time) *SessionFixture
func (*SessionFixture) Data ¶
func (f *SessionFixture) Data(data []byte) *SessionFixture
func (*SessionFixture) ExpiresAt ¶
func (f *SessionFixture) ExpiresAt(expiresAt time.Time) *SessionFixture
func (*SessionFixture) GetEntity ¶
func (f *SessionFixture) GetEntity() storage.Session
func (*SessionFixture) ID ¶
func (f *SessionFixture) ID(iD uuid.UUID) *SessionFixture
func (*SessionFixture) IdentityID ¶
func (f *SessionFixture) IdentityID(identityID uuid.UUID) *SessionFixture
func (*SessionFixture) PullUpdates ¶
func (f *SessionFixture) PullUpdates(tb testing.TB) *SessionFixture
func (*SessionFixture) PushUpdates ¶
func (f *SessionFixture) PushUpdates(tb testing.TB) *SessionFixture