Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 429 for tc (0.06 sec)

  1. pkg/apis/core/pods/helpers_test.go

    			expectedValue: "10.244.0.6",
    		},
    	}
    	for _, tc := range testCases {
    		label, value, err := ConvertDownwardAPIFieldLabel(tc.version, tc.label, tc.value)
    		if err != nil {
    			if tc.expectedErr {
    				continue
    			}
    			t.Errorf("ConvertDownwardAPIFieldLabel(%s, %s, %s) failed: %s",
    				tc.version, tc.label, tc.value, err)
    		}
    		if tc.expectedLabel != label || tc.expectedValue != value {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jul 14 01:35:30 UTC 2023
    - 6.1K bytes
    - Viewed (0)
  2. staging/src/k8s.io/cli-runtime/pkg/genericclioptions/jsonpath_flags_test.go

    			}
    
    			p, err := printFlags.ToPrinter(tc.outputFormat)
    			if tc.expectNoMatch {
    				if !IsNoCompatiblePrinterError(err) {
    					t.Fatalf("expected no printer matches for output format %q", tc.outputFormat)
    				}
    				return
    			}
    			if IsNoCompatiblePrinterError(err) {
    				t.Fatalf("expected to match template printer for output format %q", tc.outputFormat)
    			}
    
    			if len(tc.expectedError) > 0 {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 02 09:47:52 UTC 2023
    - 6.7K bytes
    - Viewed (0)
  3. cluster/gce/gci/apiserver_etcd_test.go

    			},
    		},
    	}
    
    	for _, tc := range testCases {
    		t.Run(tc.desc, func(t *testing.T) {
    			c := newManifestTestCase(t, kubeAPIServerManifestFileName, kubeAPIServerStartFuncName, nil)
    			defer c.tearDown()
    			tc.env.KubeHome = c.kubeHome
    			tc.env.KubeAPIServerRunAsUser = strconv.Itoa(os.Getuid())
    
    			c.mustInvokeFunc(
    				tc.env,
    				[]string{"configure-helper.sh", kubeAPIServerConfigScriptName},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 18 11:14:24 UTC 2021
    - 5.6K bytes
    - Viewed (0)
  4. staging/src/k8s.io/cli-runtime/pkg/genericclioptions/template_flags_test.go

    			}
    
    			p, err := printFlags.ToPrinter(tc.outputFormat)
    			if tc.expectNoMatch {
    				if !IsNoCompatiblePrinterError(err) {
    					t.Fatalf("expected no printer matches for output format %q", tc.outputFormat)
    				}
    				return
    			}
    			if IsNoCompatiblePrinterError(err) {
    				t.Fatalf("expected to match template printer for output format %q", tc.outputFormat)
    			}
    
    			if len(tc.expectedError) > 0 {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 02 09:47:52 UTC 2023
    - 5.9K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiextensions-apiserver/pkg/registry/customresource/strategy_test.go

    				},
    			},
    		},
    	}
    	for _, tc := range tcs {
    		if tc.statusEnabled {
    			strategy.status = &apiextensions.CustomResourceSubresourceStatus{}
    		} else {
    			strategy.status = nil
    		}
    		strategy.PrepareForUpdate(context.TODO(), tc.obj, tc.old)
    		if !reflect.DeepEqual(tc.obj, tc.expected) {
    			t.Errorf("test %q failed: expected: %v, got %v", tc.name, tc.expected, tc.obj)
    		}
    	}
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  6. security/pkg/pki/util/generate_csr_test.go

    				ECSigAlg: "ED25519",
    			},
    			err: errors.New("csr cert generation fails due to unsupported EC signature algorithm"),
    		},
    	}
    
    	for id, tc := range cases {
    		csrPem, _, err := GenCSR(tc.csrOptions)
    		if err != nil {
    			if tc.err != nil {
    				if err.Error() == tc.err.Error() {
    					continue
    				}
    				t.Fatalf("%s: expected error to match expected error: %v", id, err)
    			} else {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Feb 25 09:40:13 UTC 2022
    - 5.5K bytes
    - Viewed (0)
  7. staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/helpers_test.go

    				}},
    			},
    			expectErr: true,
    		},
    	}
    
    	for i, tc := range tc {
    		inCopy := tc.in.DeepCopy()
    		out, err := LabelSelectorAsSelector(tc.in)
    		// after calling LabelSelectorAsSelector, tc.in shouldn't be modified
    		if !reflect.DeepEqual(inCopy, tc.in) {
    			t.Errorf("[%v]expected:\n\t%#v\nbut got:\n\t%#v", i, inCopy, tc.in)
    		}
    		if err == nil && tc.expectErr {
    			t.Errorf("[%v]expected error but got none.", i)
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 12 15:46:12 UTC 2023
    - 7.1K bytes
    - Viewed (0)
  8. pkg/controller/ttlafterfinished/ttlafterfinished_controller_test.go

    			t.Errorf("%s: invalid test setup; error message must not be empty for error cases", tc.name)
    		}
    		if tc.expectErr && !strings.Contains(gotErr.Error(), tc.expectErrStr) {
    			t.Errorf("%s: expected error message contains %q, got %v", tc.name, tc.expectErrStr, gotErr)
    		}
    		if !tc.expectErr {
    			if *gotTimeLeft != *tc.expectedTimeLeft {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Jun 18 18:46:26 UTC 2023
    - 5.3K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiserver/plugin/pkg/audit/truncate/truncate_test.go

    			},
    			wantBatchCount: 2,
    		},
    	}
    	for _, tc := range testCases {
    		tc := tc
    		t.Run(tc.desc, func(t *testing.T) {
    			t.Parallel()
    
    			var gotBatchCount int
    			fb := &fake.Backend{
    				OnRequest: func(events []*auditinternal.Event) {
    					gotBatchCount++
    				},
    			}
    			b := NewBackend(fb, tc.config, auditv1.SchemeGroupVersion)
    			b.ProcessEvents(tc.events...)
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jul 30 07:56:39 UTC 2018
    - 3.7K bytes
    - Viewed (0)
  10. pkg/kubelet/types/pod_status_test.go

    		v1.PodReadyToStartContainers,
    	}
    
    	for _, tc := range trueCases {
    		if !PodConditionByKubelet(tc) {
    			t.Errorf("Expect %q to be condition owned by kubelet.", tc)
    		}
    	}
    
    	falseCases := []v1.PodConditionType{
    		v1.PodConditionType("abcd"),
    		v1.PodConditionType(v1.PodReasonUnschedulable),
    	}
    
    	for _, tc := range falseCases {
    		if PodConditionByKubelet(tc) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 2.2K bytes
    - Viewed (0)
Back to top