Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 26 for testCase (0.2 sec)

  1. cmd/signature-v4-utils_test.go

    			if testCase.inputHeaderKey != "" {
    				q.Add(testCase.inputHeaderKey, testCase.inputHeaderValue)
    			}
    			inputReq.URL.RawQuery = q.Encode()
    		} else if testCase.inputHeaderKey != "" {
    			inputReq.Header.Set(testCase.inputHeaderKey, testCase.inputHeaderValue)
    		}
    		inputReq.ParseForm()
    
    		actualResult := skipContentSha256Cksum(inputReq)
    		if testCase.expectedResult != actualResult {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 05 21:26:41 GMT 2024
    - 14.3K bytes
    - Viewed (0)
  2. cmd/net_test.go

    		{"http://8.8.8.8:9000", "http://localhost:9000", false, nil},
    	}
    
    	for _, testCase := range testCases {
    		testCase := testCase
    		t.Run("", func(t *testing.T) {
    			sameAddr, err := sameLocalAddrs(testCase.addr1, testCase.addr2)
    			if testCase.expectedErr != nil && err == nil {
    				t.Errorf("should fail but succeeded")
    			}
    			if testCase.expectedErr == nil && err != nil {
    				t.Errorf("should succeed but failed with %v", err)
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 19 08:43:09 GMT 2024
    - 9.3K bytes
    - Viewed (0)
  3. 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)
    		}
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 26 00:31:12 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  4. cmd/xl-storage_test.go

    			expectedErr: errFileNameTooLong,
    		},
    	}
    
    	for i, testCase := range testCases {
    		if err := xlStorage.RenameFile(context.Background(), testCase.srcVol, testCase.srcPath, testCase.destVol, testCase.destPath); err != testCase.expectedErr {
    			t.Fatalf("TestXLStorage %d:  Expected the error to be : \"%v\", got: \"%v\".", i+1, testCase.expectedErr, err)
    		}
    	}
    }
    
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 11 17:45:28 GMT 2024
    - 66.7K bytes
    - Viewed (0)
  5. cmd/object-handlers_test.go

    				getPutObjectURL("", testCase.bucketName, testCase.objectName),
    				int64(testCase.dataLen), testCase.chunkSize, bytes.NewReader(testCase.data),
    				testCase.accessKey, testCase.secretKey)
    		case testCase.contentEncoding == "":
    			req, err = newTestStreamingSignedRequest(http.MethodPut,
    				getPutObjectURL("", testCase.bucketName, testCase.objectName),
    				int64(testCase.dataLen), testCase.chunkSize, bytes.NewReader(testCase.data),
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 160K bytes
    - Viewed (0)
  6. cmd/post-policy_test.go

    		},
    	}
    
    	for i, testCase := range testCasesV4BadData {
    		// initialize HTTP NewRecorder, this records any mutations to response writer inside the handler.
    		rec := httptest.NewRecorder()
    
    		testCase.policy = fmt.Sprintf(testCase.policy, testCase.dates...)
    
    		req, perr := newPostRequestV4Generic("", bucketName, testCase.objectName, testCase.data, testCase.accessKey,
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 19 16:45:54 GMT 2024
    - 29.6K bytes
    - Viewed (0)
  7. cmd/sts-handlers_test.go

    		// Init and run test on ErasureSet backend.
    		{serverType: "ErasureSet", signer: signerV4},
    	}
    	testCases := []*TestSuiteIAM{}
    	for _, bt := range baseTestCases {
    		testCases = append(testCases,
    			newTestSuiteIAM(bt, false),
    			newTestSuiteIAM(bt, true),
    		)
    	}
    	for i, testCase := range testCases {
    		etcdStr := ""
    		if testCase.withEtcdBackend {
    			etcdStr = " (with etcd backend)"
    		}
    		t.Run(
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 25 15:50:16 GMT 2024
    - 85.7K bytes
    - Viewed (0)
  8. cmd/jwt_test.go

    					"Authorization": []string{"invalid-token"},
    				},
    			},
    			expectedErr: errAuthentication,
    		},
    	}
    
    	for i, testCase := range testCases {
    		_, _, _, gotErr := metricsRequestAuthenticate(testCase.req)
    		if testCase.expectedErr != gotErr {
    			t.Errorf("Test %d, expected err %s, got %s", i+1, testCase.expectedErr, gotErr)
    		}
    	}
    }
    
    func BenchmarkParseJWTStandardClaims(b *testing.B) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Fri Apr 19 16:45:14 GMT 2024
    - 4.5K bytes
    - Viewed (0)
  9. cmd/format-erasure_test.go

    				}{
    					Version: "0",
    				},
    			},
    			false,
    		},
    	}
    
    	// Valid all test cases.
    	for i, testCase := range testCases {
    		if err := checkFormatErasureValue(testCase.format, nil); err != nil && testCase.success {
    			t.Errorf("Test %d: Expected failure %s", i+1, err)
    		}
    	}
    }
    
    // Tests getFormatErasureInQuorum()
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Apr 15 08:25:46 GMT 2024
    - 12.9K bytes
    - Viewed (0)
  10. maven-compat/src/test/java/org/apache/maven/repository/legacy/resolver/conflict/AbstractConflictResolverTest.java

        public AbstractConflictResolverTest(String roleHint) throws Exception {
            this.roleHint = roleHint;
        }
    
        // TestCase methods -------------------------------------------------------
    
        /*
         * @see junit.framework.TestCase#setUp()
         */
        @BeforeEach
        public void setUp() throws Exception {
    Java
    - Registered: Sun Apr 28 03:35:10 GMT 2024
    - Last Modified: Thu Apr 25 05:46:50 GMT 2024
    - 4.4K bytes
    - Viewed (0)
Back to top