diff --git a/.gx/lastpubver b/.gx/lastpubver index 51819ef..5890c14 100644 --- a/.gx/lastpubver +++ b/.gx/lastpubver @@ -1 +1 @@ -2.0.11: QmQAGG1zxfePqj2t7bLxyN8AFccZ889DDR9Gn8kVLDrGZo +2.0.13: QmPiemjiKBC9VA7vZF82m4x1oygtg2c2YVqag8PX7dN1BD diff --git a/README.md b/README.md index fac964f..e730e27 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ This repository falls under the IPFS [Code of Conduct](https://github.com/ipfs/c ### Want to hack on IPFS? -[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/contributing.md) +[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md) ## License MIT diff --git a/package.json b/package.json index c4b0e5f..1cea17e 100644 --- a/package.json +++ b/package.json @@ -15,9 +15,9 @@ }, { "author": "whyrusleeping", - "hash": "QmRKLtwMw131aK7ugC3G7ybpumMz78YrJe5dzneyindvG1", + "hash": "QmNTCey11oxhb1AxDnQBRHtdhap6Ctud872NjAYPYYXPuc", "name": "go-multiaddr", - "version": "1.3.6" + "version": "1.4.0" }, { "author": "whyrusleeping", @@ -33,21 +33,21 @@ }, { "author": "jbenet", - "hash": "QmQVUtnrNGtCRkCMpXgpApfzQjc8FDaDVxHqWH8cnZQeh5", + "hash": "QmZcLBXKaFe8ND5YHPkJRAwmhJGrVsi1JqDZNyJ4nRK5Mj", "name": "go-multiaddr-net", - "version": "1.6.6" + "version": "1.7.1" }, { "author": "whyrusleeping", - "hash": "QmXZVrmSiWPyuET6BMbGK3PjzVnQBrcnYc4GkHKhK2KXLp", + "hash": "QmYW5GSNZboYmtWWhzYr4yS3WDAuettAMh3iDLn5nGvwtc", "name": "mafmt", - "version": "1.2.9" + "version": "1.2.10" }, { "author": "whyrusleeping", - "hash": "QmcqU6QUDSXprb1518vYDGczrTJTyGwLG9eUa5iNX4xUtS", + "hash": "QmY5Grm8pJdiSSVsYxx4uNRgweY72EmYwuSDbRnbFok3iY", "name": "go-libp2p-peer", - "version": "2.4.3" + "version": "3.0.0" }, { "author": "multiformats", @@ -95,6 +95,6 @@ "license": "MIT", "name": "go-libp2p-peerstore", "releaseCmd": "git commit -a -m \"gx publish $VERSION\"", - "version": "2.0.11" + "version": "2.0.13" } diff --git a/test/addr_book_suite.go b/test/addr_book_suite.go index 534829b..dfd720a 100644 --- a/test/addr_book_suite.go +++ b/test/addr_book_suite.go @@ -88,6 +88,21 @@ func testAddAddress(ab pstore.AddrBook) func(*testing.T) { time.Sleep(1200 * time.Millisecond) testHas(t, addrs[2:], ab.Addrs(id)) }) + + t.Run("adding an existing address with an earlier expiration is noop", func(t *testing.T) { + id := generatePeerIds(1)[0] + addrs := generateAddrs(3) + + ab.AddAddrs(id, addrs, time.Hour) + + // same address as before but with a lower TTL + ab.AddAddrs(id, addrs[2:], time.Second) + + // after the initial TTL has expired, check that all three addresses are still present (i.e. the TTL on + // the modified one was not shortened). + time.Sleep(2100 * time.Millisecond) + testHas(t, addrs, ab.Addrs(id)) + }) } } diff --git a/test/keybook_suite.go b/test/keybook_suite.go index f4f8496..9803128 100644 --- a/test/keybook_suite.go +++ b/test/keybook_suite.go @@ -140,6 +140,8 @@ func testKeyBookPeers(kb pstore.KeyBook) func(t *testing.T) { func testInlinedPubKeyAddedOnRetrieve(kb pstore.KeyBook) func(t *testing.T) { return func(t *testing.T) { + t.Skip("key inlining disabled for now: see libp2p/specs#111") + if peers := kb.PeersWithKeys(); len(peers) > 0 { t.Error("expected peers to be empty on init") }