- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestDeletedAtOneOr (0.09 sec)
-
tests/soft_delete_test.go
_ = json.Unmarshal(b, result) if result.DeletedAt != expected.DeletedAt { t.Errorf("Failed, result.DeletedAt: %v is not same as expected.DeletedAt: %v", result.DeletedAt, expected.DeletedAt) } } func TestDeletedAtOneOr(t *testing.T) { actualSQL := DB.ToSQL(func(tx *gorm.DB) *gorm.DB { return tx.Or("id = ?", 1).Find(&User{}) }) if !regexp.MustCompile(` WHERE id = 1 AND .users.\..deleted_at. IS NULL`).MatchString(actualSQL) {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Feb 01 06:40:55 UTC 2023 - 5.7K bytes - Viewed (0)