Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestSave (0.05 sec)

  1. tests/update_test.go

    		t.Errorf("failed to save company, got err: %v", err)
    	}
    	if err := DB.Save(&company).Error; err != nil || company.ID != create.ID {
    		t.Errorf("failed to save company, got err: %v", err)
    	}
    }
    
    func TestSave(t *testing.T) {
    	user := *GetUser("save", Config{})
    	DB.Create(&user)
    
    	if err := DB.First(&User{}, "name = ?", "save").Error; err != nil {
    		t.Fatalf("failed to find created user")
    	}
    
    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