- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 61 for Kappen (0.18 sec)
-
tests/migrate_test.go
t.Fatalf("Got error when tried to create index: %+v", err) } if err := DB.Migrator().RenameIndex(&IndexStruct{}, "idx_index_structs_name", "idx_users_name_1"); err != nil { t.Fatalf("no error should happen when rename index, but got %v", err) } if !DB.Migrator().HasIndex(&IndexStruct{}, "idx_users_name_1") { t.Fatalf("Should find index for user's name after rename") }
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Mar 18 11:24:16 GMT 2024 - 56.2K bytes - Viewed (0) -
tests/preload_suits_test.go
} want := []Level1{want1, want2} var got []Level1 err := DB.Preload("Level2.Level3.Level4s").Find(&got).Error if err != nil { t.Error(err) } for _, level1 := range append(got, want...) { sort.Slice(level1.Level2.Level3.Level4s, func(i, j int) bool { return level1.Level2.Level3.Level4s[i].ID > level1.Level2.Level3.Level4s[j].ID }) } if !reflect.DeepEqual(got, want) {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Fri Mar 18 05:38:46 GMT 2022 - 30.3K bytes - Viewed (0) -
tests/update_test.go
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Dec 04 03:50:58 GMT 2023 - 30.3K bytes - Viewed (0) -
tests/scanner_valuer_test.go
) func TestScannerValuer(t *testing.T) { DB.Migrator().DropTable(&ScannerValuerStruct{}) if err := DB.Migrator().AutoMigrate(&ScannerValuerStruct{}); err != nil { t.Fatalf("no error should happen when migrate scanner, valuer struct, got error %v", err) } data := ScannerValuerStruct{ Name: sql.NullString{String: "name", Valid: true}, Gender: &sql.NullString{String: "M", Valid: true},
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Wed Jun 07 07:02:07 GMT 2023 - 10.6K bytes - Viewed (0) -
tests/scan_test.go
if err != nil { t.Errorf("Not error should happen, got %v", err) } type Result struct { Name string Age int } var results []Result for rows.Next() { var result Result if err := DB.ScanRows(rows, &result); err != nil { t.Errorf("should get no error, but got %v", err) } results = append(results, result) } sort.Slice(results, func(i, j int) bool {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat May 28 14:18:07 GMT 2022 - 8.2K bytes - Viewed (0) -
tests/associations_has_one_test.go
} // Append DB.Model(&users).Association("Account").Append( &Account{Number: "account-slice-append-1"}, &Account{Number: "account-slice-append-2"}, &Account{Number: "account-slice-append-3"}, ) AssertAssociationCount(t, users, "Account", 3, "After Append") // Replace -> same as append // Delete
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Thu Jan 06 07:02:53 GMT 2022 - 6.8K bytes - Viewed (0) -
schema/utils.go
switch result.Kind() { case reflect.Struct: reflectResults = reflect.Append(reflectResults, result.Addr()) case reflect.Slice, reflect.Array: for i := 0; i < result.Len(); i++ { if elem := result.Index(i); elem.Kind() == reflect.Ptr { reflectResults = reflect.Append(reflectResults, elem) } else { reflectResults = reflect.Append(reflectResults, elem.Addr()) } } } } }
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat Aug 19 13:35:14 GMT 2023 - 5.5K bytes - Viewed (0) -
tests/helper_test.go
} for i := 0; i < config.Pets; i++ { user.Pets = append(user.Pets, &Pet{Name: name + "_pet_" + strconv.Itoa(i+1)}) } for i := 0; i < config.Toys; i++ { user.Toys = append(user.Toys, Toy{Name: name + "_toy_" + strconv.Itoa(i+1)}) } for i := 0; i < config.Tools; i++ { user.Tools = append(user.Tools, Tools{Name: name + "_tool_" + strconv.Itoa(i+1)}) } if config.Company {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Tue Mar 19 03:50:28 GMT 2024 - 8K bytes - Viewed (0) -
schema/index.go
if idx.Where == "" { idx.Where = index.Where } if idx.Comment == "" { idx.Comment = index.Comment } if idx.Option == "" { idx.Option = index.Option } idx.Fields = append(idx.Fields, index.Fields...) sort.Slice(idx.Fields, func(i, j int) bool { return idx.Fields[i].priority < idx.Fields[j].priority }) indexes[index.Name] = idx } } }
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sun Feb 04 07:49:19 GMT 2024 - 3.7K bytes - Viewed (0) -
prepare_stmt.go
if err != nil { cacheStmt.prepareErr = err db.Mux.Lock() delete(db.Stmts, query) db.Mux.Unlock() return Stmt{}, err } db.Mux.Lock() cacheStmt.Stmt = stmt db.PreparedSQL = append(db.PreparedSQL, query) db.Mux.Unlock() return cacheStmt, nil } func (db *PreparedStmtDB) BeginTx(ctx context.Context, opt *sql.TxOptions) (ConnPool, error) {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Thu Mar 28 08:47:39 GMT 2024 - 6.4K bytes - Viewed (0)