- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 20 for makeClient (0.49 sec)
-
pilot/pkg/config/kube/crdclient/client_test.go
"istio.io/istio/pkg/kube/kubetypes" "istio.io/istio/pkg/slices" "istio.io/istio/pkg/test" "istio.io/istio/pkg/test/util/assert" "istio.io/istio/pkg/test/util/retry" ) func makeClient(t *testing.T, schemas collection.Schemas, f kubetypes.DynamicObjectFilter) (model.ConfigStoreController, kube.CLIClient) { fake := kube.NewFakeClient() if f != nil { kube.SetObjectFilter(fake, f) }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri May 10 02:58:52 UTC 2024 - 14.1K bytes - Viewed (0) -
pkg/controller/statefulset/stateful_pod_control_test.go
set := newStatefulSet(3) pod := newStatefulSetPod(set, 0) fakeClient := &fake.Clientset{} claimIndexer := cache.NewIndexer(cache.MetaNamespaceKeyFunc, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}) claimLister := corelisters.NewPersistentVolumeClaimLister(claimIndexer) control := NewStatefulPodControl(fakeClient, nil, claimLister, recorder)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jun 05 19:06:41 UTC 2024 - 35.5K bytes - Viewed (0) -
pkg/volume/csi/csi_attacher_test.go
shouldFail: true, }, } for i, tc := range testCases { t.Run(tc.name, func(t *testing.T) { fakeClient := fakeclient.NewSimpleClientset() plug, tmpDir := newTestPlugin(t, fakeClient) defer os.RemoveAll(tmpDir) fakeWatcher := watch.NewRaceFreeFake() fakeClient.Fake.PrependWatchReactor("volumeattachments", core.DefaultWatchReactor(fakeWatcher, nil)) attacher, err := plug.NewAttacher()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Apr 18 12:23:16 UTC 2024 - 58.1K bytes - Viewed (0) -
pkg/kubelet/util/manager/cache_based_manager_test.go
store.Get("ns1", "s20") store.Get("ns1", "s3") actions = fakeClient.Actions() assert.Equal(t, 3, len(actions), "unexpected actions: %#v", actions) fakeClient.ClearActions() } func TestRegisterIdempotence(t *testing.T) { fakeClient := &fake.Clientset{} fakeClock := testingclock.NewFakeClock(time.Now()) store := newSecretStore(fakeClient, fakeClock, noObjectTTL, time.Minute)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jun 04 06:25:43 UTC 2024 - 19.6K bytes - Viewed (0) -
pkg/controller/ttl/ttl_controller_test.go
}, } for i, testCase := range testCases { fakeClient := &fake.Clientset{} ttlController := &Controller{ kubeClient: fakeClient, } err := ttlController.patchNodeWithAnnotation(context.TODO(), testCase.node, v1.ObjectTTLAnnotationKey, testCase.ttlSeconds) if err != nil { t.Errorf("%d: unexpected error: %v", i, err) continue } actions := fakeClient.Actions()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat May 04 18:33:12 UTC 2024 - 7.1K bytes - Viewed (0) -
pkg/volume/csi/csi_mounter_test.go
} }) } } func TestMounterSetUpSimple(t *testing.T) { fakeClient := fakeclient.NewSimpleClientset() plug, tmpDir := newTestPlugin(t, fakeClient) transientError := volumetypes.NewTransientOperationFailure("") defer os.RemoveAll(tmpDir) testCases := []struct { name string
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 50.1K bytes - Viewed (0) -
pkg/volume/csi/csi_plugin_test.go
for _, test := range tests { t.Run(test.name, func(t *testing.T) { driver := getTestCSIDriver(testDriver, nil, nil, supported) fakeClient := fakeclient.NewSimpleClientset(driver) plug, tmpDir := newTestPlugin(t, fakeClient) defer os.RemoveAll(tmpDir) registerFakePlugin(testDriver, "endpoint", []string{"1.2.0"}, t) mounter, err := plug.NewMounter( test.spec,
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 41.8K bytes - Viewed (0) -
cmd/kubeadm/app/cmd/upgrade/common.go
// Print GET and LIST requests dryRunOpts.PrintGETAndLIST = true fakeclient := apiclient.NewDryRunClientWithOpts(dryRunOpts) // As we know the return of Discovery() of the fake clientset is of type *fakediscovery.FakeDiscovery // we can convert it to that struct. fakeclientDiscovery, ok := fakeclient.Discovery().(*fakediscovery.FakeDiscovery) if !ok {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu May 16 08:34:39 UTC 2024 - 10.1K bytes - Viewed (0) -
pkg/volume/util/operationexecutor/operation_generator_test.go
"k8s.io/kubernetes/pkg/features" "github.com/stretchr/testify/assert" v1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/uuid" fakeclient "k8s.io/client-go/kubernetes/fake" "k8s.io/component-base/metrics/testutil" "k8s.io/kubernetes/pkg/volume" csitesting "k8s.io/kubernetes/pkg/volume/csi/testing" volumetesting "k8s.io/kubernetes/pkg/volume/testing"
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 16.2K bytes - Viewed (0) -
cmd/kubeadm/app/cmd/token_test.go
t.Errorf("RunGenerateToken's output did not match expected regex; wanted: [%s], got: [%s]", tokenExpectedRegex, output) } } func TestRunCreateToken(t *testing.T) { var buf bytes.Buffer fakeClient := &fake.Clientset{} fakeClient.AddReactor("get", "secrets", func(action core.Action) (handled bool, ret runtime.Object, err error) { return true, nil, apierrors.NewNotFound(v1.Resource("secrets"), "foo") }) testCases := []struct {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Apr 23 05:47:48 UTC 2024 - 13.6K bytes - Viewed (0)