- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for AddReactor (0.1 sec)
-
pkg/kubelet/volumemanager/reconciler/reconciler_test.go
DevicePath: "fake/path", }) } fakeClient.AddReactor("get", "nodes", func(action core.Action) (bool, runtime.Object, error) { return true, &v1.Node{ ObjectMeta: metav1.ObjectMeta{Name: string(nodeName)}, Status: v1.NodeStatus{ VolumesAttached: attachedVolumes, }, }, nil }, ) fakeClient.AddReactor("*", "*", func(action core.Action) (bool, runtime.Object, error) {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Apr 09 07:34:33 UTC 2024 - 75.4K bytes - Viewed (0) -
pkg/kubelet/volumemanager/populator/desired_state_of_world_populator_test.go
Other string = "other" ) func pluginPVOmittingClient(dswp *desiredStateOfWorldPopulator) { fakeClient := &fake.Clientset{} fakeClient.AddReactor("get", "persistentvolumeclaims", func(action core.Action) (bool, runtime.Object, error) { return false, nil, nil }) fakeClient.AddReactor("get", "persistentvolumes", func(action core.Action) (bool, runtime.Object, error) { return false, nil, nil }) dswp.kubeClient = fakeClient }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 51.4K bytes - Viewed (0) -
pkg/controller/podautoscaler/replica_calculator_test.go
podNamePrefix = "test-pod" numContainersPerPod = 2 ) func (tc *replicaCalcTestCase) prepareTestClientSet() *fake.Clientset { fakeClient := &fake.Clientset{} fakeClient.AddReactor("list", "pods", func(action core.Action) (handled bool, ret runtime.Object, err error) { obj := &v1.PodList{} podsCount := int(tc.currentReplicas) // Failed pods are not included in tc.currentReplicas
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Aug 19 03:31:34 UTC 2023 - 68.4K bytes - Viewed (0) -
plugin/pkg/admission/limitranger/admission_test.go
func newMockClientForTest(limitRanges []corev1.LimitRange) *fake.Clientset { mockClient := &fake.Clientset{} mockClient.AddReactor("list", "limitranges", func(action core.Action) (bool, runtime.Object, error) { limitRangeList := &corev1.LimitRangeList{ ListMeta: metav1.ListMeta{ ResourceVersion: fmt.Sprintf("%d", len(limitRanges)), },
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Mar 06 00:00:21 UTC 2024 - 51.5K bytes - Viewed (0) -
pkg/controller/history/controller_history_test.go
existing []struct { parent metav1.Object revision *apps.ControllerRevision } err bool } testFn := func(test *testcase, t *testing.T) { client := fake.NewSimpleClientset() client.AddReactor("*", "*", func(action core.Action) (bool, runtime.Object, error) { switch action := action.(type) { case core.PatchActionImpl: var found *apps.ControllerRevision for i := range test.existing {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Aug 21 13:31:28 UTC 2023 - 49.1K bytes - Viewed (0) -
pkg/controller/disruption/disruption_test.go
replicas := int32(10) pods := int32(4) maxUnavailable := int32(5) _, ctx := ktesting.NewTestContext(t) dc, ps := newFakeDisruptionController(ctx) dc.scaleClient.AddReactor("get", "customresources", func(action core.Action) (handled bool, ret runtime.Object, err error) { obj := &autoscalingapi.Scale{ ObjectMeta: metav1.ObjectMeta{ Namespace: metav1.NamespaceDefault,
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 04 18:33:12 UTC 2024 - 50K bytes - Viewed (0) -
pkg/kubelet/status/status_manager_test.go
} } func TestSyncPodIgnoresNotFound(t *testing.T) { client := fake.Clientset{} syncer := newTestManager(&client) client.AddReactor("get", "pods", func(action core.Action) (bool, runtime.Object, error) { return true, nil, errors.NewNotFound(api.Resource("pods"), "test-pod") }) syncer.SetPodStatus(getTestPod(), getRandomPodStatus())
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu May 02 16:27:19 UTC 2024 - 68.1K bytes - Viewed (0) -
pkg/controller/replicaset/replica_set_test.go
func TestControllerUpdateStatusWithFailure(t *testing.T) { rs := newReplicaSet(1, map[string]string{"foo": "bar"}) fakeClient := &fake.Clientset{} fakeClient.AddReactor("get", "replicasets", func(action core.Action) (bool, runtime.Object, error) { return true, rs, nil }) fakeClient.AddReactor("*", "*", func(action core.Action) (bool, runtime.Object, error) { return true, &apps.ReplicaSet{}, fmt.Errorf("fake error") })
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 04 18:33:12 UTC 2024 - 69.2K bytes - Viewed (0)