Search Options

Results per page
Sort
Preferred Languages
Advance

Results 71 - 80 of 323 for tc (0.12 sec)

  1. pkg/kubelet/container/helpers_test.go

    			},
    			0x11a6d6d6,
    		},
    	}
    	for _, tc := range tests {
    		t.Run(tc.name, func(t *testing.T) {
    			containerCopy := tc.container.DeepCopy()
    			hash := HashContainer(tc.container)
    			assert.Equal(t, tc.expectedHash, hash, "[%s]", tc.name)
    			assert.Equal(t, containerCopy, tc.container, "[%s]", tc.name)
    		})
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 22 01:55:46 UTC 2024
    - 24.5K bytes
    - Viewed (0)
  2. pkg/slices/slices_test.go

    		},
    		{
    			name:  "EmptySlice",
    			slice: []int{},
    			v:     1,
    			want:  false,
    		},
    	}
    
    	for _, tc := range testCases {
    		t.Run(tc.name, func(t *testing.T) {
    			if got := Contains(tc.slice, tc.v); got != tc.want {
    				t.Errorf("Contains(%v, %v) = %v; want %v", tc.slice, tc.v, got, tc.want)
    			}
    		})
    	}
    }
    
    func TestFindFunc(t *testing.T) {
    	emptyElement := []string{}
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri May 10 23:33:56 UTC 2024
    - 18.2K bytes
    - Viewed (0)
  3. pkg/kubelet/cm/memorymanager/state/state_checkpoint_test.go

    	for _, tc := range testCases {
    		t.Run(tc.description, func(t *testing.T) {
    			// ensure there is no previous checkpoint
    			assert.NoError(t, cpm.RemoveCheckpoint(testingCheckpoint), "could not remove testing checkpoint")
    
    			// prepare checkpoint for testing
    			if strings.TrimSpace(tc.checkpointContent) != "" {
    				checkpoint := &testutil.MockCheckpoint{Content: tc.checkpointContent}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Jul 30 03:35:26 UTC 2022
    - 10.6K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apiserver/pkg/server/egressselector/egress_selector_test.go

    			cs, err := NewEgressSelector(tc.input)
    			if err == nil && tc.expectedError != nil {
    				t.Errorf("calling NewEgressSelector expected error: %s, did not get it", *tc.expectedError)
    			}
    			if err != nil && tc.expectedError == nil {
    				t.Errorf("unexpected error calling NewEgressSelector got: %#v", err)
    			}
    			if err != nil && tc.expectedError != nil && err.Error() != *tc.expectedError {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Jan 26 22:41:29 UTC 2023
    - 12.3K bytes
    - Viewed (0)
  5. pkg/controller/volume/attachdetach/attach_detach_controller_test.go

    	if tc.podName != "" {
    		newPod := controllervolumetesting.NewPodWithVolume(tc.podName, tc.volName, tc.podNodeName)
    		_, err = adc.kubeClient.CoreV1().Pods(newPod.ObjectMeta.Namespace).Create(tCtx, newPod, metav1.CreateOptions{})
    		if err != nil {
    			t.Fatalf("Run failed with error. Failed to create a new pod: <%v>", err)
    		}
    		podInformer.GetIndexer().Add(newPod)
    	}
    	if tc.pvName != "" {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 18 11:00:37 UTC 2024
    - 24.2K bytes
    - Viewed (0)
  6. pkg/registry/core/service/ipallocator/ipallocator_test.go

    			}
    			if f := r.Used(); f != (tc.free - 1) {
    				t.Errorf("[%s] wrong free: expected %d, got %d", tc.name, tc.free-1, f)
    			}
    			if err := r.Allocate(released); err != nil {
    				t.Fatal(err)
    			}
    			if f := r.Free(); f != 0 {
    				t.Errorf("[%s] wrong free: expected %d, got %d", tc.name, 0, f)
    			}
    			if f := r.Used(); f != tc.free {
    				t.Errorf("[%s] wrong free: expected %d, got %d", tc.name, tc.free, f)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Jun 25 13:14:46 UTC 2023
    - 24.2K bytes
    - Viewed (0)
  7. pkg/registry/core/service/ipallocator/bitmap_test.go

    				t.Errorf("[%s] wrong CIDR: expected %v, got %v", tc.name, tc.cidr, rCIDR.String())
    			}
    
    			if r.IPFamily() != tc.family {
    				t.Errorf("[%s] wrong IP family: expected %v, got %v", tc.name, tc.family, r.IPFamily())
    			}
    
    			if f := r.Used(); f != 0 {
    				t.Errorf("[%s]: wrong used: expected %d, got %d", tc.name, 0, f)
    			}
    			found := sets.NewString()
    			count := 0
    			for r.Free() > 0 {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jan 25 20:32:40 UTC 2023
    - 21.1K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/storage/storagebackend/factory/factory_test.go

    				HealthcheckTimeout: 3 * time.Second,
    			},
    			responseTime: 5 * time.Second,
    			want:         context.DeadlineExceeded,
    		},
    	}
    
    	for _, tc := range tests {
    		t.Run(tc.name, func(t *testing.T) {
    			ready := make(chan struct{})
    			tc.cfg.Transport.ServerList = client.Endpoints()
    			newETCD3Client = func(c storagebackend.TransportConfig) (*clientv3.Client, error) {
    				defer close(ready)
    				dummyKV := mockKV{
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Aug 29 15:58:10 UTC 2022
    - 12.1K bytes
    - Viewed (0)
  9. src/image/gif/reader_test.go

    		// byte, and 2-bit LZW literals.
    		b.WriteString("\x2c\x00\x00\x00\x00\x02\x00\x01\x00\x00\x02")
    		if tc.nPix > 0 {
    			enc := lzwEncode(make([]byte, tc.nPix))
    			if len(enc)+tc.extraExisting > 0xff {
    				t.Errorf("nPix=%d, extraExisting=%d, extraSeparate=%d: compressed length %d is too large",
    					tc.nPix, tc.extraExisting, tc.extraSeparate, len(enc))
    				continue
    			}
    
    			// Write the size of the data sub-block containing the LZW data.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 11 16:15:54 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  10. pkg/kubelet/kuberuntime/kuberuntime_container_linux_test.go

    			if tc.swapDisabledOnNode {
    				expectSwapDisabled(tc.cgroupVersion, resourcesC1, resourcesC2)
    				return
    			}
    
    			if !tc.nodeSwapFeatureGateEnabled || tc.cgroupVersion == cgroupV1 || (tc.swapBehavior == types.LimitedSwap && tc.qosClass != v1.PodQOSBurstable) {
    				expectNoSwap(tc.cgroupVersion, resourcesC1, resourcesC2)
    				return
    			}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 41K bytes
    - Viewed (0)
Back to top