MCPcopy
hub / github.com/dropbox/godropbox / TestInsertSingleValue

Method TestInsertSingleValue

database/sqlbuilder/statement_test.go:267–275  ·  view source on GitHub ↗
(c *gc.C)

Source from the content-addressed store, hash-verified

265}
266
267func (s *StmtSuite) TestInsertSingleValue(c *gc.C) {
268 sql, err := table1.Insert(table1Col1).Add(Literal(1)).String("db")
269 c.Assert(err, gc.IsNil)
270
271 c.Assert(
272 sql,
273 gc.Equals,
274 "INSERT INTO `db`.`table1` (`table1`.`col1`) VALUES (1)")
275}
276
277func (s *StmtSuite) TestInsertDate(c *gc.C) {
278 date := time.Date(1999, 1, 2, 3, 4, 5, 0, time.UTC)

Callers

nothing calls this directly

Calls 4

LiteralFunction · 0.85
StringMethod · 0.65
AddMethod · 0.65
InsertMethod · 0.65

Tested by

no test coverage detected