Skip to content
This repository was archived by the owner on Aug 23, 2019. It is now read-only.

Commit 21720d7

Browse files
committed
chore: update pnet package version
test: add skipped test back in and update it
1 parent 5d17831 commit 21720d7

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"dirty-chai": "^2.0.1",
4444
"gulp": "^3.9.1",
4545
"libp2p-mplex": "~0.7.0",
46-
"libp2p-pnet": "github:libp2p/js-libp2p-pnet#feat/initial",
46+
"libp2p-pnet": "~0.1.0",
4747
"libp2p-secio": "~0.10.0",
4848
"libp2p-spdy": "~0.12.1",
4949
"libp2p-tcp": "~0.12.0",

test/pnet.node.js

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -142,12 +142,14 @@ describe('Private Network', function () {
142142
* Currently this test will time out instead of returning an error properly. This is the same issue
143143
* in ipfs/interop, https://github.com/ipfs/interop/pull/24/commits/179978996ecaef39e78384091aa9669dcdb94cc0
144144
*/
145-
it.skip('should fail to talk to a switch on a different private network', function (done) {
146-
this.timeout(30e3)
147-
switchD.dial(switchA._peerInfo, (err, conn) => {
145+
it('should fail to talk to a switch on a different private network', function (done) {
146+
switchD.dial(switchA._peerInfo, (err) => {
148147
expect(err).to.exist()
149-
expect(conn).to.not.exist()
150-
expect(Object.keys(switchD.muxedConns).length).to.equal(0)
151148
})
149+
150+
// A successful connection will return in well under 2 seconds
151+
setTimeout(() => {
152+
done()
153+
}, 2000)
152154
})
153155
})

0 commit comments

Comments
 (0)