- Sort Score
- Result 10 results
- Languages All
Results 191 - 200 of 1,123 for testCases (0.17 sec)
-
pkg/api/node/util_test.go
package node import ( "testing" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/sets" "k8s.io/kubernetes/pkg/apis/node" ) func TestWarnings(t *testing.T) { testcases := []struct { name string template *node.RuntimeClass expected []string }{ { name: "null", template: nil, expected: nil, }, { name: "no warning",
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Sep 25 11:04:08 UTC 2023 - 2K bytes - Viewed (0) -
pkg/volume/csi/csi_attacher_test.go
if err != nil { t.Error(err) } if watch != nil { watch.Modify(attach) } } } func TestAttacherAttach(t *testing.T) { testCases := []struct { name string nodeName string driverName string volumeName string attachID string spec *volume.Spec
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Apr 18 12:23:16 UTC 2024 - 58.1K bytes - Viewed (0) -
staging/src/k8s.io/cli-runtime/pkg/genericclioptions/jsonpath_flags_test.go
t.Fatalf("unexpected error: %v", err) } defer func(tempFile *os.File) { tempFile.Close() os.Remove(tempFile.Name()) }(jsonpathFile) fmt.Fprintf(jsonpathFile, "{ .metadata.name }\n") testCases := []struct { name string outputFormat string templateArg string expectedError string expectedParseError string expectedOutput string expectNoMatch bool }{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Jun 02 09:47:52 UTC 2023 - 6.7K bytes - Viewed (0) -
pkg/controller/certificates/rootcacertpublisher/metrics_test.go
corev1 "k8s.io/api/core/v1" apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/component-base/metrics/legacyregistry" "k8s.io/component-base/metrics/testutil" ) func TestSyncCounter(t *testing.T) { testCases := []struct { desc string err error metrics []string want string }{ { desc: "nil error", err: nil, metrics: []string{ "root_ca_cert_publisher_sync_total", },
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Sep 16 12:05:32 UTC 2021 - 2.7K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/endpoints/discovery/addresses_test.go
publicAddressCIDRMap[0], { ClientCIDR: "10.0.0.0/24", ServerAddress: "serviceIP", }, } internalIP := "10.0.0.1" publicIP := "1.1.1.1" testCases := []struct { Request http.Request ExpectedMap []metav1.ServerAddressByClientCIDR }{ { Request: http.Request{}, ExpectedMap: publicAddressCIDRMap, }, { Request: http.Request{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Aug 20 08:42:09 UTC 2021 - 2.7K bytes - Viewed (0) -
cmd/kubeadm/app/cmd/config_test.go
if len(actual) != defaultNumberOfImages { t.Fatalf("Expected %v but found %v images", defaultNumberOfImages, len(actual)) } } func TestImagesListRunWithCustomConfigPath(t *testing.T) { testcases := []struct { name string expectedImageCount int // each string provided here must appear in at least one image returned by Run expectedImageSubstrings []string configContents []byte }{
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed May 29 06:58:01 UTC 2024 - 13K bytes - Viewed (0) -
pkg/volume/csi/csi_plugin_test.go
shouldFail: true, }, } for _, tc := range testCases { // Arrange & Act err := PluginHandler.ValidatePlugin(tc.pluginName, tc.endpoint, tc.versions) // Assert if tc.shouldFail && err == nil { t.Fatalf("expecting ValidatePlugin to fail, but got nil error for testcase: %#v", tc) } if !tc.shouldFail && err != nil {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 24 18:25:29 UTC 2024 - 41.8K bytes - Viewed (0) -
pkg/controller/certificates/rootcacertpublisher/publisher_test.go
ObjectMeta: metav1.ObjectMeta{Name: ns}, Status: v1.NamespaceStatus{ Phase: v1.NamespaceTerminating, }, } type action struct { verb string name string } testcases := map[string]struct { ExistingConfigMaps []*v1.ConfigMap AddedNamespace *v1.Namespace UpdatedNamespace *v1.Namespace DeletedConfigMap *v1.ConfigMap UpdatedConfigMap *v1.ConfigMap
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Apr 12 15:46:16 UTC 2023 - 7.9K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/authentication/serviceaccount/util_test.go
if !reflect.DeepEqual(userInfo, test.expectedUserInfo) { t.Errorf("expected %#v but got %#v", test.expectedUserInfo, userInfo) } }) } } func TestMakeUsername(t *testing.T) { testCases := map[string]struct { Namespace string Name string ExpectedErr bool }{ "valid": { Namespace: "foo", Name: "bar", ExpectedErr: false, }, "empty": {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Oct 30 21:15:10 UTC 2023 - 7.7K bytes - Viewed (0) -
pkg/kubelet/kubelet_volumes_linux_test.go
if err != nil { return err } return fmt.Errorf("dir %q still exists", dir) } func TestCleanupOrphanedPodDirs(t *testing.T) { if testing.Short() { t.Skip("skipping test in short mode.") } testCases := map[string]struct { pods []*v1.Pod prepareFunc func(kubelet *Kubelet) error validateFunc func(kubelet *Kubelet) error expectErr bool }{ "nothing-to-do": {}, "pods-dir-not-found": {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Jul 30 03:35:26 UTC 2022 - 8.9K bytes - Viewed (0)