mirror of
https://github.com/fluencelabs/js-libp2p
synced 2025-04-04 00:31:04 +00:00
20 lines
470 B
JavaScript
20 lines
470 B
JavaScript
|
/* eslint-env mocha */
|
||
|
'use strict'
|
||
|
|
||
|
const Prepare = require('./utils/prepare')
|
||
|
|
||
|
describe('default', function () {
|
||
|
const prepare = Prepare(3, { pollInterval: 1000 })
|
||
|
before(prepare.before)
|
||
|
after(prepare.after)
|
||
|
|
||
|
it('does not kick out any peer', (done) => {
|
||
|
prepare.connManagers().forEach((connManager) => {
|
||
|
connManager.on('disconnected', () => {
|
||
|
throw new Error('should not have disconnected')
|
||
|
})
|
||
|
})
|
||
|
setTimeout(done, 1900)
|
||
|
})
|
||
|
})
|