From 30433f95d838b839f8428a97c6a3e4b9742af830 Mon Sep 17 00:00:00 2001 From: Kexian Zhong Date: Thu, 5 Mar 2020 11:55:49 +0800 Subject: [PATCH] Fix TestTransactionWithBlock panic case Panic will rollback case should use "transaction-3". --- main_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main_test.go b/main_test.go index b51fe413..c5e19c59 100644 --- a/main_test.go +++ b/main_test.go @@ -535,7 +535,7 @@ func TestTransactionWithBlock(t *testing.T) { }) }) - if err := DB.First(&User{}, "name = ?", "transcation").Error; err == nil { + if err := DB.First(&User{}, "name = ?", "transcation-3").Error; err == nil { t.Errorf("Should not find record after panic rollback") } }