Unit tests cleanup.
This commit is contained in:
parent
52bdd4b59f
commit
3c4b078941
8 changed files with 150 additions and 179 deletions
|
|
@ -49,11 +49,12 @@ var table3 = NewTable(
|
|||
table3Col1,
|
||||
table3StrCol)
|
||||
|
||||
func getTestSerialize(t *testing.T, exp expression) string {
|
||||
func assertExpressionSerialize(t *testing.T, expression expression, query string, args ...interface{}) {
|
||||
out := queryData{}
|
||||
err := exp.serialize(select_statement, &out)
|
||||
err := expression.serialize(select_statement, &out)
|
||||
|
||||
assert.NilError(t, err)
|
||||
|
||||
return out.buff.String()
|
||||
assert.DeepEqual(t, out.buff.String(), query)
|
||||
assert.DeepEqual(t, out.args, args)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue