mirror of
https://github.com/libp2p/go-libp2p.git
synced 2026-04-22 16:17:19 +08:00
Remove assertion that assumes a certain CI network environment
The number of interfaces attached to the CI is unknown to this test. We shouldn't assert on a specific count. Co-Authored-By: gammazero <11790789+gammazero@users.noreply.github.com>
This commit is contained in:
committed by
Marco Munizaga
parent
92c6f0eac2
commit
46986fcdbf
@@ -224,8 +224,8 @@ func TestAllAddrs(t *testing.T) {
|
||||
|
||||
// listen on IPv4 0.0.0.0
|
||||
require.NoError(t, h.Network().Listen(ma.StringCast("/ip4/0.0.0.0/tcp/0")))
|
||||
// should contain localhost and private local addr along with previous listen address
|
||||
require.Len(t, h.AllAddrs(), 3)
|
||||
// should contain more addresses than just the one from last time
|
||||
require.Greater(t, len(h.AllAddrs()), 1)
|
||||
// Should still contain the original addr.
|
||||
require.True(t, ma.Contains(h.AllAddrs(), firstAddr), "should still contain the original addr")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user