From f4076845477b10ac2453a16377a8383467aafe72 Mon Sep 17 00:00:00 2001 From: Jason Moiron Date: Mon, 20 Feb 2017 23:34:47 -0500 Subject: [PATCH] fix a few tests which were testing the wrong thing --- sqlx_context_test.go | 2 +- sqlx_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sqlx_context_test.go b/sqlx_context_test.go index 40ae5ca1..85e112bd 100644 --- a/sqlx_context_test.go +++ b/sqlx_context_test.go @@ -793,7 +793,7 @@ func TestUsageContext(t *testing.T) { t.Error("Expected an error") } err = stmt1.GetContext(ctx, &jason, "DoesNotExist User 2") - if err != nil { + if err == nil { t.Fatal(err) } diff --git a/sqlx_test.go b/sqlx_test.go index f87769db..5752773a 100644 --- a/sqlx_test.go +++ b/sqlx_test.go @@ -967,7 +967,7 @@ func TestUsage(t *testing.T) { t.Error("Expected an error") } err = stmt1.Get(&jason, "DoesNotExist User 2") - if err != nil { + if err == nil { t.Fatal(err) }