Skip to content

Commit 1cb0079

Browse files
committed
Add EquateComparable for netip.Prefix to cmp.Diff in testConfigure
1 parent 49dce0a commit 1cb0079

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

client_integration_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import (
1212
"time"
1313

1414
"github.com/google/go-cmp/cmp"
15+
"github.com/google/go-cmp/cmp/cmpopts"
1516
"github.com/mikioh/ipaddr"
1617
"golang.zx2c4.com/wireguard/wgctrl"
1718
"golang.zx2c4.com/wireguard/wgctrl/internal/wginternal"
@@ -198,7 +199,7 @@ func testConfigure(t *testing.T, c *wgctrl.Client, d *wgtypes.Device) {
198199
})
199200
}
200201

201-
if diff := cmp.Diff(d, dn); diff != "" {
202+
if diff := cmp.Diff(d, dn, cmpopts.EquateComparable(netip.Prefix{})); diff != "" {
202203
t.Fatalf("unexpected Device from Device (-want +got):\n%s", diff)
203204
}
204205

0 commit comments

Comments
 (0)