Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for ExpectedMap (0.25 sec)

  1. staging/src/k8s.io/apiserver/pkg/endpoints/discovery/addresses_test.go

    	publicIP := "1.1.1.1"
    	testCases := []struct {
    		Request     http.Request
    		ExpectedMap []metav1.ServerAddressByClientCIDR
    	}{
    		{
    			Request:     http.Request{},
    			ExpectedMap: publicAddressCIDRMap,
    		},
    		{
    			Request: http.Request{
    				Header: map[string][]string{
    					"X-Real-Ip": {internalIP},
    				},
    			},
    			ExpectedMap: internalAddressCIDRMap,
    		},
    		{
    			Request: http.Request{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Aug 20 08:42:09 UTC 2021
    - 2.7K bytes
    - Viewed (0)
  2. src/net/http/cgi/integration_test.go

    	h := &Handler{
    		Path: os.Args[0],
    		Root: "/test.go",
    	}
    	expectedMap := map[string]string{
    		"nil-request-body": "false",
    	}
    	_ = runCgiTest(t, h, "POST /test.go?nil-request-body=1 HTTP/1.0\nHost: example.com\n\n", expectedMap)
    	_ = runCgiTest(t, h, "POST /test.go?nil-request-body=1 HTTP/1.0\nHost: example.com\nContent-Length: 0\n\n", expectedMap)
    }
    
    func TestChildContentType(t *testing.T) {
    	testenv.MustHaveExec(t)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 07 18:42:44 UTC 2023
    - 5.5K bytes
    - Viewed (0)
  3. src/net/http/cgi/host_test.go

    func runCgiTest(t *testing.T, h *Handler,
    	httpreq string,
    	expectedMap map[string]string, checks ...func(reqInfo map[string]string)) *httptest.ResponseRecorder {
    	rw := httptest.NewRecorder()
    	req := newRequest(httpreq)
    	h.ServeHTTP(rw, req)
    	runResponseChecks(t, rw, expectedMap, checks...)
    	return rw
    }
    
    func runResponseChecks(t *testing.T, rw *httptest.ResponseRecorder,
    	expectedMap map[string]string, checks ...func(reqInfo map[string]string)) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 18:29:59 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  4. pkg/proxy/endpointslicecache_test.go

    			cmc.Check(t)
    		})
    	}
    }
    
    func TestEndpointInfoByServicePort(t *testing.T) {
    	testCases := map[string]struct {
    		namespacedName types.NamespacedName
    		endpointSlices []*discovery.EndpointSlice
    		hostname       string
    		expectedMap    spToEndpointMap
    	}{
    		"simple use case with 3 endpoints": {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Apr 29 21:07:21 UTC 2024
    - 24.9K bytes
    - Viewed (0)
  5. pkg/controller/volume/persistentvolume/testing/testing.go

    	}
    	if !reflect.DeepEqual(expectedMap, gotMap) {
    		// Print ugly but useful diff of expected and received objects for
    		// easier debugging.
    		return fmt.Errorf("Volume check failed [A-expected, B-got]: %s", cmp.Diff(expectedMap, gotMap))
    	}
    	return nil
    }
    
    // CheckClaims compares all expectedClaims with set of claims at the end of the
    // test and reports differences.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 12 15:46:12 UTC 2023
    - 20.1K bytes
    - Viewed (0)
  6. cmd/server_test.go

    }
    
    func (s *TestSuiteCommon) TestCors(c *check) {
    	expectedMap := http.Header{}
    	expectedMap.Set("Access-Control-Allow-Credentials", "true")
    	expectedMap.Set("Access-Control-Allow-Origin", "http://foobar.com")
    	expectedMap["Access-Control-Expose-Headers"] = []string{
    		"Date",
    		"Etag",
    		"Server",
    		"Connection",
    		"Accept-Ranges",
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 115.3K bytes
    - Viewed (0)
Back to top