mirror of https://github.com/status-im/consul.git
add missing line from prototest.AssertDeepEqual (#12645)
This commit is contained in:
parent
8aebca5794
commit
64e1501bda
|
@ -3,11 +3,15 @@ package prototest
|
|||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/golang/protobuf/proto"
|
||||
"github.com/google/go-cmp/cmp"
|
||||
)
|
||||
|
||||
func AssertDeepEqual(t *testing.T, x, y interface{}, opts ...cmp.Option) {
|
||||
t.Helper()
|
||||
|
||||
opts = append(opts, cmp.Comparer(proto.Equal))
|
||||
|
||||
if diff := cmp.Diff(x, y, opts...); diff != "" {
|
||||
t.Fatalf("assertion failed: values are not equal\n--- expected\n+++ actual\n%v", diff)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue