Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for StringDiff (0.6 sec)

  1. staging/src/k8s.io/apimachinery/pkg/util/diff/diff.go

    	"github.com/google/go-cmp/cmp"
    	"k8s.io/apimachinery/pkg/util/dump"
    )
    
    func legacyDiff(a, b interface{}) string {
    	return cmp.Diff(a, b)
    }
    
    // StringDiff diffs a and b and returns a human readable diff.
    // DEPRECATED: use github.com/google/go-cmp/cmp.Diff
    func StringDiff(a, b string) string {
    	return legacyDiff(a, b)
    }
    
    // ObjectDiff prints the diff of two go objects and fails if the objects
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 12 15:45:31 UTC 2023
    - 3.4K bytes
    - Viewed (0)
  2. cmd/kubeadm/app/cmd/upgrade/plan_test.go

    			}
    
    			actual := rt.buf.String()
    			if actual != rt.expected {
    
    				t.Errorf("failed PrintUpgradePlan:\n\nexpected:\n%s\n\nactual:\n%s\n\ndiff:\n%s", rt.expected, actual, diff.StringDiff(actual, rt.expected))
    			}
    		})
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sun Mar 03 03:03:29 UTC 2024
    - 27.3K bytes
    - Viewed (0)
Back to top