fixture

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2020 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Overview

Package fixture provides test suites to test implementations of the interfaces in the findb package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoginUser

func LoginUser(t *testing.T, doer db.Doer, store LoginStore)

func NoUserByName

func NoUserByName(t *testing.T, store UserByNameStore)

func RemoveUserByName

func RemoveUserByName(t *testing.T, store RemoveUserByNameStore)

func UpdateUser

func UpdateUser(t *testing.T, store UpdateUserStore)

func UserById

func UserById(t *testing.T, store UserByIdStore)

func UserByName

func UserByName(t *testing.T, store UserByNameStore)

func Users

func Users(t *testing.T, store UsersStore)

Types

type AccountByIdStore

type AccountByIdStore interface {
	MinimalStore
	findb.AccountByIdRunner
}

type ActiveAccountsStore

type ActiveAccountsStore interface {
	MinimalStore
	findb.ActiveAccountsRunner
}

type EntriesByAccountIdStore

type EntriesByAccountIdStore interface {
	MinimalStore
	findb.EntriesByAccountIdRunner
}

type EntriesStore

type EntriesStore interface {
	MinimalStore
	findb.EntriesRunner
}

type EntryAccountFixture

type EntryAccountFixture struct {
	Doer db.Doer
}

EntryAccountFixture tests implementations of interfaces in the findb package that access entries and accounts. Each exported method is one test.

func (EntryAccountFixture) AccountUpdates

func (f EntryAccountFixture) AccountUpdates(t *testing.T, store AccountByIdStore)

func (EntryAccountFixture) ActiveAccounts

func (f EntryAccountFixture) ActiveAccounts(
	t *testing.T, store ActiveAccountsStore)

func (EntryAccountFixture) ApplyRecurringEntries

func (f EntryAccountFixture) ApplyRecurringEntries(
	t *testing.T,
	store RecurringEntriesApplier)

func (EntryAccountFixture) ConcurrentUpdateDetection

func (f EntryAccountFixture) ConcurrentUpdateDetection(
	t *testing.T, store EntryByIdWithEtagStore)

func (EntryAccountFixture) ConcurrentUpdateSkipped

func (f EntryAccountFixture) ConcurrentUpdateSkipped(
	t *testing.T, store EntryByIdStore)

func (EntryAccountFixture) DeleteEntries

func (f EntryAccountFixture) DeleteEntries(t *testing.T, store EntriesStore)

func (EntryAccountFixture) EntriesByAccountId

func (f EntryAccountFixture) EntriesByAccountId(
	t *testing.T, store EntriesByAccountIdStore)

func (EntryAccountFixture) EntriesByAccountIdNilPtr

func (f EntryAccountFixture) EntriesByAccountIdNilPtr(
	t *testing.T, store EntriesByAccountIdStore)

func (EntryAccountFixture) ListEntries

func (f EntryAccountFixture) ListEntries(t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesDateRange

func (f EntryAccountFixture) ListEntriesDateRange(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesDateRangeAndUnreviewed

func (f EntryAccountFixture) ListEntriesDateRangeAndUnreviewed(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesEmptyOptions

func (f EntryAccountFixture) ListEntriesEmptyOptions(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesJustEndDate

func (f EntryAccountFixture) ListEntriesJustEndDate(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesJustStartDate

func (f EntryAccountFixture) ListEntriesJustStartDate(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) ListEntriesUnreviewed

func (f EntryAccountFixture) ListEntriesUnreviewed(
	t *testing.T, store EntriesStore)

func (EntryAccountFixture) RemoveAccount

func (f EntryAccountFixture) RemoveAccount(
	t *testing.T, store RemoveAccountStore)

func (EntryAccountFixture) SaveAndLoadEntry

func (f EntryAccountFixture) SaveAndLoadEntry(
	t *testing.T, store EntryByIdStore)

func (EntryAccountFixture) UnreconciledEntries

func (f EntryAccountFixture) UnreconciledEntries(
	t *testing.T, store UnreconciledEntriesStore)

func (EntryAccountFixture) UnreconciledEntriesNoAccount

func (f EntryAccountFixture) UnreconciledEntriesNoAccount(
	t *testing.T, store UnreconciledEntriesStore)

func (EntryAccountFixture) UpdateAccount

func (f EntryAccountFixture) UpdateAccount(
	t *testing.T, store UpdateAccountStore)

func (EntryAccountFixture) UpdateAccountImportSD

func (f EntryAccountFixture) UpdateAccountImportSD(
	t *testing.T, store UpdateAccountImportSDStore)

func (EntryAccountFixture) UpdateEntry

func (f EntryAccountFixture) UpdateEntry(t *testing.T, store EntryByIdStore)

func (EntryAccountFixture) UpdateEntrySkipped

func (f EntryAccountFixture) UpdateEntrySkipped(
	t *testing.T, store EntryByIdStore)

type EntryByIdStore

type EntryByIdStore interface {
	MinimalStore
	findb.EntryByIdRunner
}

type EntryByIdWithEtagStore

type EntryByIdWithEtagStore interface {
	MinimalStore
	findb.EntryByIdRunner
	findb.AccountByIdRunner
}

type LoginStore

type LoginStore interface {
	UserByNameStore
	findb.UpdateUserRunner
}

type MinimalStore

type MinimalStore interface {
	findb.AddAccountRunner
	findb.DoEntryChangesRunner
}

type RemoveUserByNameStore

type RemoveUserByNameStore interface {
	UserByNameStore
	findb.RemoveUserByNameRunner
}

type UnreconciledEntriesStore

type UnreconciledEntriesStore interface {
	MinimalStore
	findb.UnreconciledEntriesRunner
}

type UpdateUserStore

type UpdateUserStore interface {
	UserByIdStore
	findb.UpdateUserRunner
}

type UserByIdStore

type UserByIdStore interface {
	findb.AddUserRunner
	findb.UserByIdRunner
}

type UserByNameStore

type UserByNameStore interface {
	findb.AddUserRunner
	findb.UserByNameRunner
}

type UsersStore

type UsersStore interface {
	findb.AddUserRunner
	findb.UsersRunner
}

Jump to

Keyboard shortcuts

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