Compare commits

...

3 Commits

Author SHA1 Message Date
David Dias
631dad8647 chore: release version v0.12.7 2016-05-06 18:28:37 +01:00
David Dias
3eac0e0dd6 chore: update contributors 2016-05-06 18:28:37 +01:00
David Dias
30d4bb641e one more test to check if connected endpoints are closed correctly 2016-05-06 18:27:19 +01:00
2 changed files with 10 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "libp2p-swarm",
"version": "0.12.6",
"version": "0.12.7",
"description": "libp2p swarm implementation in JavaScript",
"main": "lib/index.js",
"jsnext:main": "src/index.js",

View File

@@ -59,10 +59,10 @@ describe('stream muxing with spdy (on TCP)', function () {
swarmA.close(closed)
swarmB.close(closed)
swarmC.close(closed)
// swarmC.close(closed)
function closed () {
if (++counter === 3) {
if (++counter === 2) {
done()
}
}
@@ -128,4 +128,11 @@ describe('stream muxing with spdy (on TCP)', function () {
}, 500)
})
})
it('close one end, make sure the other does not blow', (done) => {
swarmC.close(() => {
// to make sure it has time to propagate
setTimeout(done, 1000)
})
})
})