Skip to content

Commit ac2e2b7

Browse files
authored
feat: async peerstore (#124)
Refactors interfaces and classes used by `libp2p-interfaces` to use the async peer store from #1058 BREAKING CHANGE: peerstore methods are now all async
1 parent 9c6cdb8 commit ac2e2b7

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -43,16 +43,16 @@
4343
},
4444
"homepage": "https://github.com/libp2p/js-libp2p-floodsub#readme",
4545
"devDependencies": {
46-
"@chainsafe/libp2p-noise": "^4.1.1",
46+
"@chainsafe/libp2p-noise": "^5.0.0",
4747
"@types/debug": "^4.1.5",
4848
"aegir": "^36.0.2",
4949
"benchmark": "^2.1.4",
5050
"buffer": "^6.0.3",
5151
"chai": "^4.3.4",
5252
"ipfs-utils": "^9.0.2",
5353
"it-pair": "^1.0.0",
54-
"libp2p": "^0.35.0",
55-
"libp2p-interfaces-compliance-tests": "^2.0.3",
54+
"libp2p": "libp2p/js-libp2p#feat/async-peerstore",
55+
"libp2p-interfaces-compliance-tests": "^4.0.2",
5656
"libp2p-mplex": "^0.10.3",
5757
"libp2p-websockets": "^0.16.0",
5858
"multiaddr": "^10.0.0",
@@ -65,7 +65,7 @@
6565
},
6666
"dependencies": {
6767
"debug": "^4.2.0",
68-
"libp2p-interfaces": "^2.0.1",
68+
"libp2p-interfaces": "^4.0.2",
6969
"time-cache": "^0.3.0",
7070
"uint8arrays": "^3.0.0"
7171
},

test/floodsub.spec.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ describe('floodsub', () => {
3939
floodsub = new Floodsub(libp2p, defOptions)
4040
})
4141

42-
beforeEach(() => {
43-
floodsub.start()
42+
beforeEach(async () => {
43+
await floodsub.start()
4444
})
4545

46-
afterEach(() => {
46+
afterEach(async () => {
4747
sinon.restore()
48-
floodsub.stop()
48+
await floodsub.stop()
4949
})
5050

5151
it('checks cache when processing incoming message', async function () {

0 commit comments

Comments
 (0)