Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TransactionsStorageMock ¶
type TransactionsStorageMock struct { // GetLastTransactionDateFunc mocks the GetLastTransactionDate method. GetLastTransactionDateFunc func(ctx context.Context, accountID string) (time.Time, error) // contains filtered or unexported fields }
TransactionsStorageMock is a mock implementation of TransactionsStorage.
func TestSomethingThatUsesTransactionsStorage(t *testing.T) { // make and configure a mocked TransactionsStorage mockedTransactionsStorage := &TransactionsStorageMock{ GetLastTransactionDateFunc: func(ctx context.Context, accountID string) (time.Time, error) { panic("mock out the GetLastTransactionDate method") }, } // use mockedTransactionsStorage in code that requires TransactionsStorage // and then make assertions. }
func (*TransactionsStorageMock) GetLastTransactionDate ¶
func (mock *TransactionsStorageMock) GetLastTransactionDate(ctx context.Context, accountID string) (time.Time, error)
GetLastTransactionDate calls GetLastTransactionDateFunc.
func (*TransactionsStorageMock) GetLastTransactionDateCalls ¶
func (mock *TransactionsStorageMock) GetLastTransactionDateCalls() []struct { Ctx context.Context AccountID string }
GetLastTransactionDateCalls gets all the calls that were made to GetLastTransactionDate. Check the length with:
len(mockedTransactionsStorage.GetLastTransactionDateCalls())
Click to show internal directories.
Click to hide internal directories.