- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestTransaction (0.16 sec)
-
tests/transaction_test.go
package tests_test import ( "context" "errors" "testing" "gorm.io/gorm" . "gorm.io/gorm/utils/tests" ) func TestTransaction(t *testing.T) { tx := DB.Begin() user := *GetUser("transaction", Config{}) if err := tx.Save(&user).Error; err != nil { t.Fatalf("No error should raise, but got %v", err) } if err := tx.First(&User{}, "name = ?", "transaction").Error; err != nil {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Sep 14 12:58:29 UTC 2024 - 12.9K bytes - Viewed (0)