- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 40 for fakePods (0.12 sec)
-
pkg/kubelet/prober/scale_test.go
).(*manager) defer cleanup(t, m) now := time.Now() fakePods := make([]*fakePod, numTestPods) for i := 0; i < numTestPods; i++ { fake, err := newFakePod(tt.http) if err != nil { t.Fatalf("unexpected error creating fake pod: %v", err) } defer fake.stop() handler := fake.probeHandler() fakePods[i] = fake pod := v1.Pod{ ObjectMeta: metav1.ObjectMeta{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Aug 16 16:33:01 UTC 2023 - 8.2K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/cacher/cacher_whitebox_test.go
func(b *testing.B) { // create sample pods fakePods := make([]example.Pod, tc.totalObjectNum, tc.totalObjectNum) for i := range fakePods { fakePods[i].Namespace = "default" fakePods[i].Name = fmt.Sprintf("pod-%d", i) fakePods[i].ResourceVersion = strconv.Itoa(i) if i%(tc.totalObjectNum/tc.expectObjectNum) == 0 { fakePods[i].Spec.NodeName = "node-0" }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jun 12 10:12:02 UTC 2024 - 82.9K bytes - Viewed (0) -
pkg/scheduler/scheduler_test.go
if !ok { return []string{}, nil } return []string{nodeName}, nil } const ( filterWithoutEnqueueExtensions = "filterWithoutEnqueueExtensions" fakeNode = "fakeNode" fakePod = "fakePod" emptyEventsToRegister = "emptyEventsToRegister" queueSort = "no-op-queue-sort-plugin" fakeBind = "bind-plugin"
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri May 17 09:07:27 UTC 2024 - 42K bytes - Viewed (0) -
pkg/kubelet/cm/memorymanager/memory_manager_test.go
}, } for _, testCase := range testCases { t.Run(testCase.description, func(t *testing.T) { iniContainerMap := containermap.NewContainerMap() iniContainerMap.Add("fakePod1", "fakeContainer1", "fakeID1") iniContainerMap.Add("fakePod1", "fakeContainer2", "fakeID2") mgr := &manager{ policy: returnPolicyByName(testCase), state: state.NewMemoryState(), containerMap: iniContainerMap,
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 05 13:01:40 UTC 2023 - 70.2K bytes - Viewed (0) -
pkg/kubelet/cm/cpumanager/policy_static_test.go
topo: topoDualSocketHT, stAssignments: state.ContainerCPUAssignments{ "fakePod": map[string]cpuset.CPUSet{ "0": cpuset.New(0, 1, 2), }, }, stDefaultCPUSet: cpuset.New(2, 3, 4, 5, 6, 7, 8, 9, 10, 11), expErr: fmt.Errorf("pod: fakePod, container: 0 cpuset: \"0-2\" overlaps with default cpuset \"2-11\""), }, {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 40.8K bytes - Viewed (0) -
pkg/kubelet/container/testing/os.go
func (f *FakeOS) Stat(path string) (os.FileInfo, error) { if f.StatFn != nil { return f.StatFn(path) } return nil, errors.New("unimplemented testing mock") } // Remove is a fake call that returns nil. func (f *FakeOS) Remove(path string) error { f.Removes = append(f.Removes, path) return nil } // RemoveAll is a fake call that just returns nil. func (f *FakeOS) RemoveAll(path string) error {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Feb 07 13:37:31 UTC 2023 - 3.7K bytes - Viewed (0) -
pkg/volume/csi/testing/testing.go
t.Fatalf("can't create temp dir: %v", err) } if client == nil { client = fakeclient.NewSimpleClientset() } client.Tracker().Add(&v1.Node{ ObjectMeta: metav1.ObjectMeta{ Name: "fakeNode", }, Spec: v1.NodeSpec{}, }) // Start informer for CSIDrivers. factory := informers.NewSharedInformerFactory(client, csi.CsiResyncPeriod) csiDriverInformer := factory.Storage().V1().CSIDrivers()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Jan 07 00:11:50 UTC 2021 - 2.2K bytes - Viewed (0) -
pkg/kubelet/container/runtime_cache_test.go
ctx := context.Background() runtime := &ctest.FakeRuntime{} cache := NewTestRuntimeCache(runtime) // Cache old pods. oldpods := []*ctest.FakePod{{Pod: &Pod{ID: "1111"}}} runtime.PodList = oldpods cache.UpdateCacheWithLock() // Update the runtime to new pods. newpods := []*ctest.FakePod{{Pod: &Pod{ID: "1111"}}, {Pod: &Pod{ID: "2222"}}, {Pod: &Pod{ID: "3333"}}} runtime.PodList = newpods
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Nov 05 13:02:13 UTC 2022 - 2.2K bytes - Viewed (0) -
pkg/kubelet/server/stats/volume_stat_calculator_test.go
volumes := map[string]volume.Volume{vol0: &fakeVolume{}, vol1: &fakeVolume{}, vol3: &fakeVolume{}} mockStats.EXPECT().ListVolumesForPod(fakePod.UID).Return(volumes, true) blockVolumes := map[string]volume.BlockVolume{vol2: &fakeBlockVolume{}} mockStats.EXPECT().ListBlockVolumesForPod(fakePod.UID).Return(blockVolumes, true) eventStore := make(chan string, 1) fakeEventRecorder := record.FakeRecorder{ Events: eventStore, }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 9.6K bytes - Viewed (0) -
pkg/kubelet/images/image_gc_manager_test.go
} fakeRuntime.AllPodList = []*containertest.FakePod{ {Pod: &container.Pod{ Containers: []*container.Container{ makeContainer(0), makeContainer(1), }, }}, } // Make 1 be more recently used than 0. _, err := manager.detectImages(ctx, zero) require.NoError(t, err) fakeRuntime.AllPodList = []*containertest.FakePod{ {Pod: &container.Pod{ Containers: []*container.Container{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 22 15:38:20 UTC 2024 - 29.2K bytes - Viewed (0)