Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for update_with_invalid_map (0.1 sec)

  1. tests/update_test.go

    	})
    
    	AssertObjEqual(t, result2, result, "Name", "Account", "Toys", "Manager", "ManagerID", "Languages")
    }
    
    func TestWithUpdateWithInvalidMap(t *testing.T) {
    	user := *GetUser("update_with_invalid_map", Config{})
    	DB.Create(&user)
    
    	if err := DB.Model(&user).Updates(map[string]string{"name": "jinzhu"}).Error; !errors.Is(err, gorm.ErrInvalidData) {
    		t.Errorf("should returns error for unsupported updating data")
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Mon Dec 04 03:50:58 UTC 2023
    - 30.3K bytes
    - Viewed (0)
Back to top