Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestJoinCount (0.22 sec)

  1. tests/joins_test.go

    	}
    
    	if len(results) != 2 || results[0].Name != "" || results[1].Name != "" {
    		t.Errorf("Should find all two pets with Join omit and should not find user's name, got %+v", results)
    		return
    	}
    }
    
    func TestJoinCount(t *testing.T) {
    	companyA := Company{Name: "A"}
    	companyB := Company{Name: "B"}
    	DB.Create(&companyA)
    	DB.Create(&companyB)
    
    	user := User{Name: "kingGo", CompanyID: &companyB.ID}
    	DB.Create(&user)
    
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Wed Apr 26 14:19:32 GMT 2023
    - 13.5K bytes
    - Viewed (1)
Back to top