- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestPreparedStmtFromTransaction (0.19 sec)
-
tests/prepared_stmt_test.go
t.Fatalf("failed to create, got error %v", err) } var result3 User if err := tx.Find(&result3, user2.ID).Error; err != nil { t.Fatalf("no error should happen but got %v", err) } } func TestPreparedStmtFromTransaction(t *testing.T) { db := DB.Session(&gorm.Session{PrepareStmt: true, SkipDefaultTransaction: true}) tx := db.Begin() defer func() { if r := recover(); r != nil { tx.Rollback() } }()
Registered: Sun Oct 27 09:35:08 UTC 2024 - Last Modified: Thu Aug 22 11:02:05 UTC 2024 - 8.5K bytes - Viewed (0)