- Sort Score
- Result 10 results
- Languages All
Results 171 - 180 of 635 for struct (0.03 sec)
-
tests/create_test.go
} var newUser User if err := DB.Where("id = ?", u1.ID).First(&newUser).Error; err != nil { t.Fatalf("errors happened when query: %v", err) } else { CheckUser(t, newUser, u1) } type user struct { ID int `gorm:"primaryKey;->:false"` Name string Age int } var u2 user if results := DB.Create(&u2); results.Error != nil { t.Fatalf("errors happened when create: %v", results.Error)
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Mon Jul 21 09:55:20 UTC 2025 - 26.8K bytes - Viewed (0) -
cmd/object-api-multipart_test.go
} res, err := obj.NewMultipartUpload(context.Background(), bucket, object, opts) if err != nil { t.Fatalf("%s : %s", instanceType, err.Error()) } uploadID := res.UploadID abortTestCases := []struct { bucketName string objName string uploadID string expectedErrType error }{ {"--", object, uploadID, BucketNameInvalid{}}, {"foo", object, uploadID, BucketNotFound{}},
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 89.4K bytes - Viewed (0) -
cmd/warm-backend-s3.go
"errors" "fmt" "io" "net/http" "net/url" "strings" "github.com/minio/madmin-go/v3" "github.com/minio/minio-go/v7" "github.com/minio/minio-go/v7/pkg/credentials" ) type warmBackendS3 struct { client *minio.Client core *minio.Core Bucket string Prefix string StorageClass string } func (s3 *warmBackendS3) ToObjectError(err error, params ...string) error {
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Sun Jun 08 16:13:30 UTC 2025 - 5.8K bytes - Viewed (0) -
clause/group_by_test.go
package clause_test import ( "fmt" "testing" "gorm.io/gorm/clause" ) func TestGroupBy(t *testing.T) { results := []struct { Clauses []clause.Interface Result string Vars []interface{} }{ { []clause.Interface{clause.Select{}, clause.From{}, clause.GroupBy{ Columns: []clause.Column{{Name: "role"}}, Having: []clause.Expression{clause.Eq{"role", "admin"}}, }},
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Thu Jan 06 07:02:53 UTC 2022 - 1.1K bytes - Viewed (0) -
cmd/endpoint_test.go
"testing" ) func TestNewEndpoint(t *testing.T) { u2, _ := url.Parse("https://example.org/path") u4, _ := url.Parse("http://192.168.253.200/path") rootSlashFoo, _ := filepath.Abs("/foo") testCases := []struct { arg string expectedEndpoint Endpoint expectedType EndpointType expectedErr error }{ {"/foo", Endpoint{&url.URL{Path: rootSlashFoo}, true, -1, -1, -1}, PathEndpointType, nil},
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 18.9K bytes - Viewed (0) -
clause/limit.go
package clause // Limit limit clause type Limit struct { Limit *int Offset int } // Name where clause name func (limit Limit) Name() string { return "LIMIT" } // Build build where clause func (limit Limit) Build(builder Builder) { if limit.Limit != nil && *limit.Limit >= 0 { builder.WriteString("LIMIT ") builder.AddVar(builder, *limit.Limit) } if limit.Offset > 0 {
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Tue Feb 06 02:54:40 UTC 2024 - 942 bytes - Viewed (0) -
cmd/xl-storage_test.go
) func TestCheckPathLength(t *testing.T) { // Check path length restrictions are not same on windows/darwin if runtime.GOOS == "windows" || runtime.GOOS == "darwin" { t.Skip() } testCases := []struct { path string expectedErr error }{ {".", errFileAccessDenied}, {"/", errFileAccessDenied}, {"..", errFileAccessDenied},
Registered: Sun Sep 07 19:28:11 UTC 2025 - Last Modified: Fri Aug 29 02:39:48 UTC 2025 - 66K bytes - Viewed (0) -
clause/locking_test.go
package clause_test import ( "fmt" "testing" "gorm.io/gorm/clause" ) func TestLocking(t *testing.T) { results := []struct { Clauses []clause.Interface Result string Vars []interface{} }{ { []clause.Interface{clause.Select{}, clause.From{}, clause.Locking{Strength: clause.LockingStrengthUpdate}}, "SELECT * FROM `users` FOR UPDATE", nil, }, {
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Fri Dec 15 08:32:56 UTC 2023 - 1.2K bytes - Viewed (0) -
clause/on_conflict.go
package clause type OnConflict struct { Columns []Column Where Where TargetWhere Where OnConstraint string DoNothing bool DoUpdates Set UpdateAll bool } func (OnConflict) Name() string { return "ON CONFLICT" } // Build build onConflict clause func (onConflict OnConflict) Build(builder Builder) { if onConflict.OnConstraint != "" { builder.WriteString("ON CONSTRAINT ")
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Fri Oct 07 05:46:20 UTC 2022 - 1.3K bytes - Viewed (0) -
clause/insert_test.go
package clause_test import ( "fmt" "testing" "gorm.io/gorm/clause" ) func TestInsert(t *testing.T) { results := []struct { Clauses []clause.Interface Result string Vars []interface{} }{ { []clause.Interface{clause.Insert{}}, "INSERT INTO `users`", nil, }, { []clause.Interface{clause.Insert{Modifier: "LOW_PRIORITY"}}, "INSERT LOW_PRIORITY INTO `users`", nil, }, {
Registered: Sun Sep 07 09:35:13 UTC 2025 - Last Modified: Tue Jun 02 01:18:01 UTC 2020 - 737 bytes - Viewed (0)