go-cmp
go-cmp copied to clipboard
Package for comparing Go values in tests
The value.TypeString function is what the rest of the package uses and is slightly cleaner than using reflect.Type.String. Updates #305
If the string has many characters that require escape sequences to print, then we need to take that into consideration and avoid byte-by-byte diffing.
We have a case where we have a linked datastructure pointing to both children and parent nodes. Due to a bug in our test implementation we were getting a result...
It's a bit of a pain writing a comparison function when we want slices to compare equal regardless of order. How about making SortSlices use a generic less function when...
For larger structs and when the API is potentially evolving it would be handy to have the inverse of `IgnoreFields`, i.e. `cmpopts.FilterFields(typ interface{}, names ...string) cmp.Option`. And for symmetry I...
Hello, I've been[ using `go-cmp`](https://godoc.org/github.com/gotestyourself/gotestyourself/assert#DeepEqual) for a bit now and I've found that the two most common cases for needing an `Option` are: 1. `AllowUnexported`/`IgnoreUnexported` - which is already easy...
Reading the docs and attempting simple implementations, I'm still not sure how to use these, since I keep getting panics. I'm going to search Github to see people using these...