- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for tidbSkip (0.06 sec)
-
tests/error_translator_test.go
if !errors.Is(err, gorm.ErrDuplicatedKey) { t.Fatalf("expected err: %v got err: %v", gorm.ErrDuplicatedKey, err) } } func TestSupportedDialectorWithErrForeignKeyViolated(t *testing.T) { tidbSkip(t, "not support the foreign key feature") type City struct { gorm.Model Name string `gorm:"unique"` } type Museum struct { gorm.Model Name string `gorm:"unique"` CityID uint
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jul 12 13:21:22 UTC 2023 - 3.1K bytes - Viewed (0) -
tests/helper_test.go
AssertObjEqual(t, friend, expect.Friends[idx], "ID", "CreatedAt", "UpdatedAt", "DeletedAt", "Name", "Age", "Birthday", "CompanyID", "ManagerID", "Active") } }) } func tidbSkip(t *testing.T, reason string) { if isTiDB() { t.Skipf("This test case skipped, because of TiDB '%s'", reason) } } func isTiDB() bool { return os.Getenv("GORM_DIALECT") == "tidb" }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Tue Mar 19 03:50:28 UTC 2024 - 8K bytes - Viewed (0) -
tests/associations_belongs_to_test.go
// unexist company id unexistCompanyID := company.ID + 9999999 user = User{Name: "invalid-user-with-invalid-belongs-to-foreign-key", CompanyID: &unexistCompanyID} if err := DB.Create(&user).Error; err == nil { tidbSkip(t, "not support the foreign key feature") t.Errorf("should have gotten foreign key violation error") } } func TestBelongsToAssociationForSlice(t *testing.T) { users := []User{
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Oct 30 09:15:49 UTC 2023 - 9.3K bytes - Viewed (0)