Skip to content

Commit

Permalink
Merge pull request #882 from jordanlewis/fix-inf-test
Browse files Browse the repository at this point in the history
bugfix to infinity timestamp test
  • Loading branch information
maddyblue authored Jul 16, 2019
2 parents d14e375 + 464bb40 commit a921722
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion encode_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ func TestInfinityTimestamp(t *testing.T) {
// try to assert []byte to time.Time
for _, q := range tc {
err = db.QueryRow(q.Query, q.Param).Scan(&resultT)
if !q.ExpectedErrorStrRegexp.MatchString(err.Error()) {
if err == nil || !q.ExpectedErrorStrRegexp.MatchString(err.Error()) {
t.Errorf("Scanning -/+infinity, expected error to match regexp %q, got %q",
q.ExpectedErrorStrRegexp, err)
}
Expand Down

0 comments on commit a921722

Please sign in to comment.