diff --git a/sqlite3_test.go b/sqlite3_test.go index 8169f3d..09e6727 100644 --- a/sqlite3_test.go +++ b/sqlite3_test.go @@ -1391,7 +1391,9 @@ func TestNilAndEmptyBytes(t *testing.T) { if err = rows.Err(); err != nil { t.Fatal(tst.name, err) } - if !bytes.Equal(scanBytes, tst.expectedBytes) { + if tst.expectedBytes == nil && scanBytes != nil { + t.Errorf("%s: %#v != %#v", tst.name, scanBytes, tst.expectedBytes) + } else if !bytes.Equal(scanBytes, tst.expectedBytes) { t.Errorf("%s: %#v != %#v", tst.name, scanBytes, tst.expectedBytes) } }