Commit Graph

2 Commits

Author SHA1 Message Date
Dave Protasowski d6a2e27f7b 🦆 Duck Typing - add a ConformsToType helper (#220)
* duck typing - add a ConformsToType helper

Unlike VerifyType, ConformsToType will return the following:
- an error when any marshalling/unmarshalling fails
- false when the concrete type does not implement the duck type
- true when the concrete type implements the duck type

* use knative/pkg kmp to handle panics raised by go-cmp
2019-01-09 19:58:42 -08:00
jonjohnsonjr 3043da57e9 Add kmp, a safe wrapper for google/go-cmp (#197)
* Add kcmp, a safe wrapper for google/go-cmp

* Returns an error instead of panicking.
* Holds common options that we use.

* Rename things

kcmp -> kmp
Diff -> SafeDiff
2018-12-08 08:39:27 -08:00