Simplify literal expressions.
This commit is contained in:
parent
4995a90483
commit
0e495a279e
26 changed files with 233 additions and 616 deletions
|
|
@ -1,8 +1,9 @@
|
|||
package sqlite
|
||||
|
||||
import (
|
||||
"github.com/stretchr/testify/require"
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
func TestRaw(t *testing.T) {
|
||||
|
|
@ -46,7 +47,7 @@ func TestRawInvalidArguments(t *testing.T) {
|
|||
|
||||
func TestRawType(t *testing.T) {
|
||||
assertSerialize(t, RawBool("table.colInt < :float", RawArgs{":float": 11.22}).IS_FALSE(),
|
||||
"(table.colInt < ?) IS FALSE", 11.22)
|
||||
"((table.colInt < ?) IS FALSE)", 11.22)
|
||||
|
||||
assertSerialize(t, RawFloat("table.colInt + &float", RawArgs{"&float": 11.22}).EQ(Float(3.14)),
|
||||
"((table.colInt + ?) = ?)", 11.22, 3.14)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue