Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,276 for checkErr (0.32 sec)

  1. tests/integration/operator/uninstall_test.go

    				if err := deleteIop(cs, iopName); err != nil {
    					t.Errorf("failed to delete iopfile: %v", err)
    				}
    
    				retry.UntilSuccessOrFail(t, func() error {
    					exist, checkErr := checkIopExist(cs, iopName)
    					if checkErr != nil {
    						return checkErr
    					}
    
    					if exist {
    						return fmt.Errorf("fail to delete iop")
    					}
    
    					return nil
    				}, retry.Timeout(deletionTimeout), retry.Delay(retryDelay))
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Apr 10 20:33:28 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apimachinery/pkg/runtime/serializer/json/json_limit_test.go

    			name:     "3MB of deeply nested slices",
    			checkErr: successOrMaxDepthError,
    			data:     []byte(`{"a":` + strings.Repeat(`[`, 3*1024*1024/2) + strings.Repeat(`]`, 3*1024*1024/2) + "}"),
    		},
    		{
    			name:     "3MB of unbalanced nested slices",
    			checkErr: nonNilError,
    			data:     []byte(`{"a":` + strings.Repeat(`[`, 3*1024*1024)),
    		},
    		{
    			name:     "3MB of deeply nested maps",
    			checkErr: successOrMaxDepthError,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Oct 20 16:49:23 UTC 2021
    - 4.5K bytes
    - Viewed (0)
  3. cmd/kubeadm/app/util/error.go

    		}
    
    		fmt.Fprint(os.Stderr, msg)
    	}
    	os.Exit(code)
    }
    
    // CheckErr prints a user friendly error to STDERR and exits with a non-zero
    // exit code. Unrecognized errors will be printed with an "error: " prefix.
    //
    // This method is generic to the command in use and may be used by non-Kubectl
    // commands.
    func CheckErr(err error) {
    	checkErr(err, fatal)
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Oct 25 16:35:10 UTC 2023
    - 3.4K bytes
    - Viewed (0)
  4. pkg/volume/util/volumepathhandler/volume_path_handler.go

    func unmapBindMountDevice(v VolumePathHandler, mapPath string, linkName string) error {
    	// Check bind mount exists
    	linkPath := filepath.Join(mapPath, string(linkName))
    	if isMountExist, checkErr := v.IsDeviceBindMountExist(linkPath); checkErr != nil {
    		return checkErr
    	} else if !isMountExist {
    		klog.Warningf("Warning: Unmap skipped because bind mount does not exist on the path: %v", linkPath)
    
    		// Check if linkPath still exists
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 20 14:49:03 UTC 2023
    - 10.7K bytes
    - Viewed (0)
  5. cmd/kubectl/kubectl.go

    	_ "k8s.io/client-go/plugin/pkg/client/auth"
    )
    
    func main() {
    	command := cmd.NewDefaultKubectlCommand()
    	if err := cli.RunNoErrOutput(command); err != nil {
    		// Pretty-print the error and exit with an error.
    		util.CheckErr(err)
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jan 10 16:09:30 UTC 2022
    - 963 bytes
    - Viewed (0)
  6. cmd/kubeadm/app/util/error_test.go

    		{"preflight error", &pferror{}, PreFlightExitCode},
    	}
    
    	for _, rt := range tests {
    		t.Run(rt.name, func(t *testing.T) {
    			codeReturned = 0
    			checkErr(rt.e, errHandle)
    			if codeReturned != rt.expected {
    				t.Errorf(
    					"failed checkErr:\n\texpected: %d\n\t  actual: %d",
    					rt.expected,
    					codeReturned,
    				)
    			}
    		})
    	}
    }
    
    func TestFormatErrMsg(t *testing.T) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Jul 04 08:41:27 UTC 2021
    - 2.4K bytes
    - Viewed (0)
  7. cmd/kubeadm/kubeadm.go

    limitations under the License.
    */
    
    package main
    
    import (
    	"k8s.io/kubernetes/cmd/kubeadm/app"
    	kubeadmutil "k8s.io/kubernetes/cmd/kubeadm/app/util"
    )
    
    func main() {
    	kubeadmutil.CheckErr(app.Run())
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Dec 27 09:57:04 UTC 2019
    - 737 bytes
    - Viewed (0)
  8. pkg/scheduler/profile/profile_test.go

    		t.Run(tc.name, func(t *testing.T) {
    			_, ctx := ktesting.NewTestContext(t)
    			ctx, cancel := context.WithCancel(ctx)
    			defer cancel()
    			m, err := NewMap(ctx, tc.cfgs, fakeRegistry, nilRecorderFactory)
    			if err := checkErr(err, tc.wantErr); err != nil {
    				t.Fatal(err)
    			}
    			if len(tc.wantErr) != 0 {
    				return
    			}
    			if len(m) != len(tc.cfgs) {
    				t.Errorf("got %d profiles, want %d", len(m), len(tc.cfgs))
    			}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Sep 20 09:49:54 UTC 2023
    - 6.6K bytes
    - Viewed (0)
  9. src/net/http/response_test.go

    		for i := 0; i < 1000; i++ {
    			if test.compressed {
    				// Otherwise this compresses too well.
    				_, err := io.ReadFull(rand.Reader, chunk)
    				checkErr(err, "rand.Reader ReadFull")
    			}
    			wr.Write(chunk)
    		}
    		if test.compressed {
    			err := wr.(*gzip.Writer).Close()
    			checkErr(err, "compressor close")
    		}
    		if test.chunked {
    			buf.WriteString("0\r\n\r\n")
    		}
    		buf.WriteString("Next Request Here")
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 19:01:29 UTC 2024
    - 23.6K bytes
    - Viewed (0)
  10. pkg/volume/csi/csi_client_test.go

    }
    
    func setupClientWithVolumeMountGroup(t *testing.T, stageUnstageSet bool, volumeMountGroupSet bool) csiClient {
    	return newFakeCsiDriverClientWithVolumeMountGroup(t, stageUnstageSet, volumeMountGroupSet)
    }
    
    func checkErr(t *testing.T, expectedAnError bool, actualError error) {
    	t.Helper()
    
    	errOccurred := actualError != nil
    
    	if expectedAnError && !errOccurred {
    		t.Error("expected an error")
    	}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 33.9K bytes
    - Viewed (0)
Back to top