testutil

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 27, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestDB

func NewTestDB(t *testing.T) *gorm.DB

Utility function that creates an in-memory database to be used for testing.

Types

type CryptorMock

type CryptorMock struct {
	mock.Mock
}

CryptorMock is a mock implementation of the Cryptor interface.

func (*CryptorMock) Decrypt

func (m *CryptorMock) Decrypt(ctx context.Context, ciphertext []byte) ([]byte, error)

func (*CryptorMock) Encrypt

func (m *CryptorMock) Encrypt(ctx context.Context, plaintext []byte) ([]byte, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL