Search Options

Results per page
Sort
Preferred Languages
Advance

Results 101 - 110 of 164 for expectedCert (0.23 sec)

  1. cmd/kubeadm/app/phases/copycerts/copycerts_test.go

    		config        *kubeadmapi.InitConfiguration
    		expectedCerts []string
    	}{
    		"local etcd": {
    			config: localEtcdCfg,
    			expectedCerts: append(
    				[]string{kubeadmconstants.EtcdCACertName, kubeadmconstants.EtcdCAKeyName},
    				commonExpectedCerts...,
    			),
    		},
    		"external etcd": {
    			config: externalEtcdCfg,
    			expectedCerts: append(
    				[]string{externalEtcdCA, externalEtcdCert, externalEtcdKey},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Jan 01 00:15:30 UTC 2023
    - 9.1K bytes
    - Viewed (0)
  2. operator/pkg/version/version_test.go

    			}
    		})
    	}
    }
    
    func TestUnmarshalYAML(t *testing.T) {
    	v := &Version{}
    	expectedErr := fmt.Errorf("test error")
    	errReturn := func(any) error { return expectedErr }
    	gotErr := v.UnmarshalYAML(errReturn)
    	if gotErr == nil {
    		t.Errorf("expected error but got nil")
    	}
    	if gotErr != expectedErr {
    		t.Errorf("error mismatch")
    	}
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 25 19:30:47 UTC 2022
    - 6.1K bytes
    - Viewed (0)
  3. plugin/pkg/admission/imagepolicy/admission_test.go

    		{statusCode: 500, expectedErr: true, expectedAuthorized: false, expectedCached: false},
    		{statusCode: 404, expectedErr: true, expectedAuthorized: false, expectedCached: false},
    		{statusCode: 403, expectedErr: true, expectedAuthorized: false, expectedCached: false},
    		{statusCode: 401, expectedErr: true, expectedAuthorized: false, expectedCached: false},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 02 06:05:06 UTC 2023
    - 32.9K bytes
    - Viewed (0)
  4. pkg/scheduler/framework/plugins/tainttoleration/taint_toleration_test.go

    	testcases := map[string]struct {
    		pod            *v1.Pod
    		oldObj, newObj interface{}
    		expectedHint   framework.QueueingHint
    		expectedErr    bool
    	}{
    		"backoff-wrong-new-object": {
    			pod:          &v1.Pod{},
    			newObj:       "not-a-pod",
    			expectedHint: framework.Queue,
    			expectedErr:  true,
    		},
    		"backoff-wrong-old-object": {
    			pod:          &v1.Pod{},
    			oldObj:       "not-a-pod",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 12 13:26:09 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  5. pkg/registry/core/pod/strategy_test.go

    			pod:           "not a pod object",
    			expectedValue: "test-pod",
    			expectedErr:   fmt.Errorf("not a pod"),
    		},
    	}
    
    	for _, tc := range tcs {
    		indexValues, err := tc.indexFunc(tc.pod)
    		if !reflect.DeepEqual(err, tc.expectedErr) {
    			t.Errorf("name %v, expected %v, got %v", tc.name, tc.expectedErr, err)
    		}
    		if err == nil && len(indexValues) != 1 && indexValues[0] != tc.expectedValue {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 76.2K bytes
    - Viewed (0)
  6. staging/src/k8s.io/cli-runtime/pkg/resource/visitor_test.go

    			if tt.isNotNil {
    				assert.Nil(t, actualErr)
    				assert.NotNil(t, actualBytes)
    			} else {
    				if tt.expectedErr != nil {
    					assert.Equal(t, tt.expectedErr, actualErr)
    				} else {
    					assert.Error(t, actualErr)
    				}
    				assert.Nil(t, actualBytes)
    			}
    
    			assert.Equal(t, tt.count, i)
    		})
    	}
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 02 09:47:52 UTC 2023
    - 9K bytes
    - Viewed (0)
  7. pkg/kubelet/kuberuntime/kuberuntime_sandbox_linux_test.go

    		pod:            newSupplementalGroupsPolicyPod(&supplementalGroupsPolicyUnSupported),
    		expectedErr:    true,
    		expectedErrMsg: "unsupported supplementalGroupsPolicy: UnSupported",
    	},
    	}
    
    	for i, test := range tests {
    		config, err := m.generatePodSandboxLinuxConfig(test.pod)
    		if test.expectedErr {
    			assert.NotEmptyf(t, err, "TestCase[%d]: %s", i, test.description)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 8K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apimachinery/pkg/apis/meta/internalversion/validation/validation_test.go

    					t.Errorf("expected %d errors but got %d errors", len(tc.expectErrors), len(errs))
    					return
    				}
    				for i, expectedErr := range tc.expectErrors {
    					if expectedErr != errs[i].Error() {
    						t.Errorf("expected error '%s' but got '%s'", expectedErr, errs[i].Error())
    					}
    				}
    				return
    			}
    			if len(errs) != 0 {
    				t.Errorf("expected no errors, but got: %v", errs)
    			}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 02 07:48:42 UTC 2023
    - 7.6K bytes
    - Viewed (0)
  9. cmd/xl-storage-free-version_test.go

    		{
    			vol:          newtierfi.Volume,
    			name:         newtierfi.Name,
    			inclFreeVers: false,
    			expectedErr:  errFileNotFound,
    		},
    	}
    
    	for _, ft := range freeVersionsTests {
    		fi, err := xl.ToFileInfo(ft.vol, ft.name, "", ft.inclFreeVers, true)
    		if err != nil && !errors.Is(err, ft.expectedErr) {
    			t.Fatalf("ToFileInfo failed due to %v", err)
    		}
    		if got := fi.TierFreeVersion(); got != ft.expectedFree {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Sat Mar 02 05:11:03 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  10. pkg/scheduler/framework/plugins/nodeports/node_ports_test.go

    	testcases := map[string]struct {
    		pod          *v1.Pod
    		oldObj       interface{}
    		expectedHint framework.QueueingHint
    		expectedErr  bool
    	}{
    		"backoff-wrong-old-object": {
    			pod:          podWithHostPort.Obj(),
    			oldObj:       "not-a-pod",
    			expectedHint: framework.Queue,
    			expectedErr:  true,
    		},
    		"skip-queue-on-unscheduled": {
    			pod:          podWithHostPort.Obj(),
    			oldObj:       st.MakePod().Obj(),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Oct 19 11:02:11 UTC 2023
    - 10.1K bytes
    - Viewed (0)
Back to top