2016-06-20 07:22:50 +02:00
|
|
|
{{- $tableNameSingular := .Table.Name | singular | titleCase -}}
|
|
|
|
{{- $tableNamePlural := .Table.Name | plural | titleCase -}}
|
|
|
|
{{- $varNamePlural := .Table.Name | plural | camelCase -}}
|
|
|
|
{{- $varNameSingular := .Table.Name | singular | camelCase -}}
|
2016-06-10 16:22:08 +02:00
|
|
|
func Test{{$tableNamePlural}}(t *testing.T) {
|
2016-08-14 10:58:36 +02:00
|
|
|
t.Parallel()
|
2016-03-21 06:15:14 +01:00
|
|
|
|
2016-08-14 10:58:36 +02:00
|
|
|
query := {{$tableNamePlural}}(nil)
|
2016-05-17 12:00:56 +02:00
|
|
|
|
2016-08-14 10:58:36 +02:00
|
|
|
if query.Query == nil {
|
|
|
|
t.Error("expected a query, got nothing")
|
2016-05-17 12:00:56 +02:00
|
|
|
}
|
2016-03-21 06:15:14 +01:00
|
|
|
}
|