Documentation ¶
Index ¶
- Constants
- func Accounts(sess db.Session) db.Store
- type Account
- type AccountsStore
- type GenericTestSuite
- func (s *GenericTestSuite) AfterTest(suiteName, testName string)
- func (s *GenericTestSuite) BeforeTest(suiteName, testName string)
- func (s *GenericTestSuite) TestComparisonOperators()
- func (s *GenericTestSuite) TestDatesAndUnicode()
- func (s *GenericTestSuite) TestExplicitAndDefaultMapping()
- func (s *GenericTestSuite) TestFibonacci()
- func (s *GenericTestSuite) TestOddEven()
- type Helper
- type Log
- type LogsStore
- type RecordTestSuite
- func (s *RecordTestSuite) AfterTest(suiteName, testName string)
- func (s *RecordTestSuite) BeforeTest(suiteName, testName string)
- func (s *RecordTestSuite) TestAccounts()
- func (s *RecordTestSuite) TestContextCanceled()
- func (s *RecordTestSuite) TestDelete()
- func (s *RecordTestSuite) TestFindOne()
- func (s *RecordTestSuite) TestInheritedTx()
- func (s *RecordTestSuite) TestSelectOnlyIDs()
- func (s *RecordTestSuite) TestSlices()
- func (s *RecordTestSuite) TestTx()
- func (s *RecordTestSuite) TestUnknownCollection()
- type SQLTestSuite
- func (s *SQLTestSuite) AfterTest(suiteName, testName string)
- func (s *SQLTestSuite) BeforeTest(suiteName, testName string)
- func (s *SQLTestSuite) TestBatchInsert()
- func (s *SQLTestSuite) TestBatchInsertNoColumns()
- func (s *SQLTestSuite) TestBatchInsertReturningKeys()
- func (s *SQLTestSuite) TestCompositeKeys()
- func (s *SQLTestSuite) TestCustomType()
- func (s *SQLTestSuite) TestDataTypes()
- func (s *SQLTestSuite) TestExhaustConnectionPool()
- func (s *SQLTestSuite) TestExpectCursorError()
- func (s *SQLTestSuite) TestFunction()
- func (s *SQLTestSuite) TestGetAllResults()
- func (s *SQLTestSuite) TestGetOneResult()
- func (s *SQLTestSuite) TestGetResultsOneByOne()
- func (s *SQLTestSuite) TestGetWithOffset()
- func (s *SQLTestSuite) TestGroup()
- func (s *SQLTestSuite) TestInlineStructs()
- func (s *SQLTestSuite) TestInsertAndDelete()
- func (s *SQLTestSuite) TestInsertDefault()
- func (s *SQLTestSuite) TestInsertIntoArtistsTable()
- func (s *SQLTestSuite) TestInsertReturning()
- func (s *SQLTestSuite) TestInsertReturningWithinTransaction()
- func (s *SQLTestSuite) TestNullableFields()
- func (s *SQLTestSuite) TestPaginator()
- func (s *SQLTestSuite) TestPaginator_Issue607()
- func (s *SQLTestSuite) TestPreparedStatementsCache()
- func (s *SQLTestSuite) TestQueryLogger()
- func (s *SQLTestSuite) TestQueryNonExistentCollection()
- func (s *SQLTestSuite) TestSelectFromSubquery()
- func (s *SQLTestSuite) TestSession()
- func (s *SQLTestSuite) TestTransactionsAndRollback()
- func (s *SQLTestSuite) TestTruncateAllCollections()
- func (s *SQLTestSuite) TestUpdate()
- func (s *SQLTestSuite) TestUpdateWithNullColumn()
- func (s *SQLTestSuite) Test_Issue565()
- type Suite
- type User
- type UsersStore
Constants ¶
View Source
const TimeZone = "Canada/Eastern"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Account ¶
type Account struct { ID uint64 `db:"id,omitempty"` Name string `db:"name"` Disabled bool `db:"disabled"` CreatedAt *time.Time `db:"created_at,omitempty"` }
func (*Account) AfterCreate ¶
type AccountsStore ¶
type AccountsStore struct {
db.Collection
}
type GenericTestSuite ¶
func (*GenericTestSuite) AfterTest ¶
func (s *GenericTestSuite) AfterTest(suiteName, testName string)
func (*GenericTestSuite) BeforeTest ¶
func (s *GenericTestSuite) BeforeTest(suiteName, testName string)
func (*GenericTestSuite) TestComparisonOperators ¶
func (s *GenericTestSuite) TestComparisonOperators()
func (*GenericTestSuite) TestDatesAndUnicode ¶
func (s *GenericTestSuite) TestDatesAndUnicode()
func (*GenericTestSuite) TestExplicitAndDefaultMapping ¶
func (s *GenericTestSuite) TestExplicitAndDefaultMapping()
func (*GenericTestSuite) TestFibonacci ¶
func (s *GenericTestSuite) TestFibonacci()
func (*GenericTestSuite) TestOddEven ¶
func (s *GenericTestSuite) TestOddEven()
type RecordTestSuite ¶
func (*RecordTestSuite) AfterTest ¶
func (s *RecordTestSuite) AfterTest(suiteName, testName string)
func (*RecordTestSuite) BeforeTest ¶
func (s *RecordTestSuite) BeforeTest(suiteName, testName string)
func (*RecordTestSuite) TestAccounts ¶
func (s *RecordTestSuite) TestAccounts()
func (*RecordTestSuite) TestContextCanceled ¶ added in v4.5.2
func (s *RecordTestSuite) TestContextCanceled()
func (*RecordTestSuite) TestDelete ¶
func (s *RecordTestSuite) TestDelete()
func (*RecordTestSuite) TestFindOne ¶
func (s *RecordTestSuite) TestFindOne()
func (*RecordTestSuite) TestInheritedTx ¶
func (s *RecordTestSuite) TestInheritedTx()
func (*RecordTestSuite) TestSelectOnlyIDs ¶
func (s *RecordTestSuite) TestSelectOnlyIDs()
func (*RecordTestSuite) TestSlices ¶
func (s *RecordTestSuite) TestSlices()
func (*RecordTestSuite) TestTx ¶
func (s *RecordTestSuite) TestTx()
func (*RecordTestSuite) TestUnknownCollection ¶
func (s *RecordTestSuite) TestUnknownCollection()
type SQLTestSuite ¶
func (*SQLTestSuite) AfterTest ¶
func (s *SQLTestSuite) AfterTest(suiteName, testName string)
func (*SQLTestSuite) BeforeTest ¶
func (s *SQLTestSuite) BeforeTest(suiteName, testName string)
func (*SQLTestSuite) TestBatchInsert ¶
func (s *SQLTestSuite) TestBatchInsert()
func (*SQLTestSuite) TestBatchInsertNoColumns ¶
func (s *SQLTestSuite) TestBatchInsertNoColumns()
func (*SQLTestSuite) TestBatchInsertReturningKeys ¶
func (s *SQLTestSuite) TestBatchInsertReturningKeys()
func (*SQLTestSuite) TestCompositeKeys ¶
func (s *SQLTestSuite) TestCompositeKeys()
func (*SQLTestSuite) TestCustomType ¶
func (s *SQLTestSuite) TestCustomType()
func (*SQLTestSuite) TestDataTypes ¶
func (s *SQLTestSuite) TestDataTypes()
func (*SQLTestSuite) TestExhaustConnectionPool ¶
func (s *SQLTestSuite) TestExhaustConnectionPool()
func (*SQLTestSuite) TestExpectCursorError ¶
func (s *SQLTestSuite) TestExpectCursorError()
func (*SQLTestSuite) TestFunction ¶
func (s *SQLTestSuite) TestFunction()
func (*SQLTestSuite) TestGetAllResults ¶
func (s *SQLTestSuite) TestGetAllResults()
func (*SQLTestSuite) TestGetOneResult ¶
func (s *SQLTestSuite) TestGetOneResult()
func (*SQLTestSuite) TestGetResultsOneByOne ¶
func (s *SQLTestSuite) TestGetResultsOneByOne()
func (*SQLTestSuite) TestGetWithOffset ¶
func (s *SQLTestSuite) TestGetWithOffset()
func (*SQLTestSuite) TestGroup ¶
func (s *SQLTestSuite) TestGroup()
func (*SQLTestSuite) TestInlineStructs ¶
func (s *SQLTestSuite) TestInlineStructs()
func (*SQLTestSuite) TestInsertAndDelete ¶
func (s *SQLTestSuite) TestInsertAndDelete()
func (*SQLTestSuite) TestInsertDefault ¶
func (s *SQLTestSuite) TestInsertDefault()
func (*SQLTestSuite) TestInsertIntoArtistsTable ¶
func (s *SQLTestSuite) TestInsertIntoArtistsTable()
func (*SQLTestSuite) TestInsertReturning ¶
func (s *SQLTestSuite) TestInsertReturning()
func (*SQLTestSuite) TestInsertReturningWithinTransaction ¶
func (s *SQLTestSuite) TestInsertReturningWithinTransaction()
func (*SQLTestSuite) TestNullableFields ¶
func (s *SQLTestSuite) TestNullableFields()
func (*SQLTestSuite) TestPaginator ¶
func (s *SQLTestSuite) TestPaginator()
func (*SQLTestSuite) TestPaginator_Issue607 ¶ added in v4.0.2
func (s *SQLTestSuite) TestPaginator_Issue607()
func (*SQLTestSuite) TestPreparedStatementsCache ¶
func (s *SQLTestSuite) TestPreparedStatementsCache()
func (*SQLTestSuite) TestQueryLogger ¶
func (s *SQLTestSuite) TestQueryLogger()
func (*SQLTestSuite) TestQueryNonExistentCollection ¶
func (s *SQLTestSuite) TestQueryNonExistentCollection()
func (*SQLTestSuite) TestSelectFromSubquery ¶ added in v4.5.3
func (s *SQLTestSuite) TestSelectFromSubquery()
func (*SQLTestSuite) TestSession ¶
func (s *SQLTestSuite) TestSession()
func (*SQLTestSuite) TestTransactionsAndRollback ¶
func (s *SQLTestSuite) TestTransactionsAndRollback()
Attempts to test database transactions.
func (*SQLTestSuite) TestTruncateAllCollections ¶
func (s *SQLTestSuite) TestTruncateAllCollections()
func (*SQLTestSuite) TestUpdate ¶
func (s *SQLTestSuite) TestUpdate()
func (*SQLTestSuite) TestUpdateWithNullColumn ¶
func (s *SQLTestSuite) TestUpdateWithNullColumn()
func (*SQLTestSuite) Test_Issue565 ¶
func (s *SQLTestSuite) Test_Issue565()
type Suite ¶
func (*Suite) BeforeTest ¶
type User ¶
type User struct { ID uint64 `db:"id,omitempty"` AccountID uint64 `db:"account_id"` Username string `db:"username"` }
func (*User) AfterCreate ¶
type UsersStore ¶
type UsersStore struct {
db.Collection
}
func Users ¶
func Users(sess db.Session) *UsersStore
Click to show internal directories.
Click to hide internal directories.