Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for NewTestContext (0.23 sec)

  1. pkg/controller/daemon/daemon_controller_test.go

    		}
    	}
    }
    
    func TestDaemonSetPodCreateExpectationsError(t *testing.T) {
    	logger, _ := ktesting.NewTestContext(t)
    	strategies := updateStrategies()
    	for _, strategy := range strategies {
    		ds := newDaemonSet("foo")
    		ds.Spec.UpdateStrategy = *strategy
    		_, ctx := ktesting.NewTestContext(t)
    		manager, podControl, _, err := newTestController(ctx, ds)
    		if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 04 18:33:12 UTC 2024
    - 111.4K bytes
    - Viewed (0)
  2. pkg/scheduler/internal/queue/scheduling_queue_test.go

    					logger, _ := ktesting.NewTestContext(t)
    					err := q.AddUnschedulableIfNotPresent(logger, poppedPod, q.SchedulingCycle())
    					if err != nil {
    						t.Fatalf("unexpected error from AddUnschedulableIfNotPresent: %v", err)
    					}
    				}},
    				{callback: func(t *testing.T, q *PriorityQueue) {
    					logger, _ := ktesting.NewTestContext(t)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 12 13:26:09 UTC 2024
    - 146.9K bytes
    - Viewed (0)
  3. pkg/proxy/ipvs/proxier_test.go

    			Namespace: namespace,
    			Labels:    map[string]string{discovery.LabelServiceName: name},
    		},
    	}
    	epsFunc(eps)
    	return eps
    }
    
    func TestCleanupLeftovers(t *testing.T) {
    	_, ctx := ktesting.NewTestContext(t)
    	ipt := iptablestest.NewFake()
    	ipvs := ipvstest.NewFake()
    	ipset := ipsettest.NewFake(testIPSetVersion)
    	fp := NewFakeProxier(ctx, ipt, ipvs, ipset, nil, nil, v1.IPv4Protocol)
    	svcIP := "10.20.30.41"
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Apr 27 01:31:57 UTC 2024
    - 186.8K bytes
    - Viewed (0)
  4. pkg/controller/job/job_controller_test.go

    	}
    }
    
    type jobInitialStatus struct {
    	active    int
    	succeed   int
    	failed    int
    	startTime *time.Time
    }
    
    func TestControllerSyncJob(t *testing.T) {
    	_, ctx := ktesting.NewTestContext(t)
    	jobConditionComplete := batch.JobComplete
    	jobConditionFailed := batch.JobFailed
    	jobConditionSuspended := batch.JobSuspended
    	referenceTime := time.Now()
    
    	testCases := map[string]struct {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 11 15:36:36 UTC 2024
    - 229.2K bytes
    - Viewed (0)
  5. pkg/scheduler/framework/runtime/framework_test.go

    		},
    	}
    
    	for _, tt := range tests {
    		t.Run(tt.name, func(t *testing.T) {
    			profile := config.KubeSchedulerProfile{Plugins: tt.plugins}
    			_, ctx := ktesting.NewTestContext(t)
    			ctx, cancel := context.WithCancel(ctx)
    			defer cancel()
    			_, err := newFrameworkWithQueueSortAndBind(ctx, registry, profile)
    			if tt.initErr && err == nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 17 09:07:27 UTC 2024
    - 103K bytes
    - Viewed (0)
  6. pkg/scheduler/schedule_one_test.go

    				t.Errorf("got binding diff (-want, +got): %s", diff)
    			}
    			stopFunc()
    		})
    	}
    }
    
    func TestSchedulerNoPhantomPodAfterExpire(t *testing.T) {
    	logger, ctx := ktesting.NewTestContext(t)
    	ctx, cancel := context.WithCancel(ctx)
    	defer cancel()
    	queuedPodStore := clientcache.NewFIFO(clientcache.MetaNamespaceKeyFunc)
    	scache := internalcache.New(ctx, 100*time.Millisecond)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 04 06:20:55 UTC 2024
    - 128.1K bytes
    - Viewed (0)
  7. pkg/controller/garbagecollector/garbagecollector_test.go

    	// No monitor will be constructed for the non-core resource, but the GC
    	// construction will not fail.
    	alwaysStarted := make(chan struct{})
    	close(alwaysStarted)
    	logger, tCtx := ktesting.NewTestContext(t)
    	gc, err := NewGarbageCollector(tCtx, client, metadataClient, rm, map[schema.GroupResource]struct{}{},
    		informerfactory.NewInformerFactory(sharedInformers, metadataInformers), alwaysStarted)
    	if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 04 18:33:12 UTC 2024
    - 111.6K bytes
    - Viewed (0)
  8. pkg/kubelet/kubelet_test.go

    	t *testing.T,
    	imageList []kubecontainer.Image,
    	controllerAttachDetachEnabled bool,
    	initFakeVolumePlugin bool,
    	localStorageCapacityIsolation bool,
    ) *TestKubelet {
    	logger, _ := ktesting.NewTestContext(t)
    
    	fakeRuntime := &containertest.FakeRuntime{
    		ImageList: imageList,
    		// Set ready conditions by default.
    		RuntimeStatus: &kubecontainer.RuntimeStatus{
    			Conditions: []kubecontainer.RuntimeCondition{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 14 16:09:17 UTC 2024
    - 106.9K bytes
    - Viewed (0)
Back to top