- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 171 for testCases (0.11 sec)
-
cmd/update_test.go
}, } for i, testCase := range testCases { if testCase.errStr != "" { got := releaseTimeToReleaseTag(testCase.t) if got != testCase.tag && testCase.errStr == "" { t.Errorf("Test %d: Expected %v but got %v", i+1, testCase.tag, got) } } tagTime, err := releaseTagToReleaseTime(testCase.tag) if err != nil && err.Error() != testCase.errStr {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Aug 14 17:11:51 UTC 2024 - 10.4K bytes - Viewed (0) -
cmd/object-api-utils_test.go
{"lalalallalallalalalallalallalala-thestring-size-is-greater-than-63", false}, } for i, testCase := range testCases { isValidBucketName := IsValidBucketName(testCase.bucketName) if testCase.shouldPass && !isValidBucketName { t.Errorf("Test case %d: Expected \"%s\" to be a valid bucket name", i+1, testCase.bucketName) } if !testCase.shouldPass && isValidBucketName {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 08 15:29:58 UTC 2024 - 24.1K bytes - Viewed (0) -
cmd/storage-rest_test.go
} result := make([]byte, 100) for i, testCase := range testCases { result = result[testCase.offset:3] _, err := storage.ReadFile(context.Background(), testCase.volumeName, testCase.objectName, testCase.offset, result, nil) expectErr := (err != nil) if expectErr != testCase.expectErr { t.Fatalf("case %v: error: expected: %v, got: %v", i+1, testCase.expectErr, expectErr) } if !testCase.expectErr {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jul 22 07:04:48 UTC 2024 - 11.5K bytes - Viewed (0) -
cmd/endpoint-ellipses_test.go
} for _, testCase := range testCases { testCase := testCase t.Run("", func(t *testing.T) { gotGCD := getDivisibleSize(testCase.totalSizes) if testCase.result != gotGCD { t.Errorf("Expected %v, got %v", testCase.result, gotGCD) } }) } } // Test tests calculating set indexes with ENV override for drive count. func TestGetSetIndexesEnvOverride(t *testing.T) { testCases := []struct {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri May 24 23:05:23 UTC 2024 - 15.2K bytes - Viewed (0) -
cmd/bucket-handlers_test.go
}, } for i, testCase := range testCases { var req *http.Request var actualContent []byte // Generate a signed or anonymous request based on the testCase if testCase.accessKey != "" { req, err = newTestSignedRequestV4(http.MethodPost, getDeleteMultipleObjectsURL("", testCase.bucket), int64(len(testCase.objects)), bytes.NewReader(testCase.objects), testCase.accessKey, testCase.secretKey, nil)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jun 10 15:50:49 UTC 2024 - 39.8K bytes - Viewed (0) -
cmd/auth-handler_test.go
} // Validates all testcases. for i, testCase := range testCases { s3Error := isReqAuthenticated(ctx, testCase.req, globalSite.Region(), serviceS3) if s3Error != testCase.s3Error { if _, err := io.ReadAll(testCase.req.Body); toAPIErrorCode(ctx, err) != testCase.s3Error { t.Fatalf("Test %d: Unexpected S3 error: want %d - got %d (got after reading request %s)", i, testCase.s3Error, s3Error, toAPIError(ctx, err).Code)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri May 24 23:05:23 UTC 2024 - 15.4K bytes - Viewed (0) -
internal/http/listener_test.go
} for testIdx, testCase := range testCases { listener, listenErrs := newHTTPListener(context.Background(), testCase.serverAddrs, TCPOptions{}, ) for i, expectedListenErr := range testCase.expectedListenErrs { if !expectedListenErr { if listenErrs[i] != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jun 10 17:41:02 UTC 2024 - 11.8K bytes - Viewed (0) -
cmd/erasure-metadata_test.go
} // Test them. for _, testCase := range testCases { index, offset, err := fi.ObjectToPartOffset(context.Background(), testCase.offset) if err != testCase.expectedErr { t.Fatalf("%+v: expected = %s, got: %s", testCase, testCase.expectedErr, err) } if index != testCase.expectedIndex { t.Fatalf("%+v: index: expected = %d, got: %d", testCase, testCase.expectedIndex, index) }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jul 25 21:02:50 UTC 2024 - 13.5K bytes - Viewed (0) -
cmd/bucket-lifecycle-handlers_test.go
}, ) { for i, testCase := range testCases { // initialize httptest Recorder, this records any mutations to response writer inside the handler. rec := httptest.NewRecorder() // construct HTTP request req, err := newTestSignedRequestV4(testCase.method, getBucketLifecycleURL("", testCase.bucketName), int64(len(testCase.body)), bytes.NewReader(testCase.body), testCase.accessKey, testCase.secretKey, nil)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jun 10 15:50:49 UTC 2024 - 11.3K bytes - Viewed (0) -
cmd/signature-v4_test.go
"Policy": []string{"policy"}, }, expected: ErrNone, }, } // Run each test case individually. for i, testCase := range testCases { _, code := doesPolicySignatureMatch(testCase.form) if code != testCase.expected { t.Errorf("(%d) expected to get %s, instead got %s", i, niceError(testCase.expected), niceError(code)) } } } func TestDoesPresignedSignatureMatch(t *testing.T) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jun 13 22:26:38 UTC 2024 - 10.5K bytes - Viewed (0)