test: use that crypto puzzle! (#135)

This commit is contained in:
David Dias
2017-12-01 09:19:44 +00:00
committed by GitHub
parent ec956c1d42
commit f602cd9f79
3 changed files with 14 additions and 11 deletions

View File

@ -36,13 +36,13 @@ function getMuxers (options) {
class Node extends libp2p {
constructor (peerInfo, peerBook, options) {
options = options || {}
const webRTCStar = new WebRTCStar()
const wsStar = new WebSocketStar()
const wrtcStar = new WebRTCStar({ id: peerInfo.id })
const wsStar = new WebSocketStar({ id: peerInfo.id })
const modules = {
transport: [
new WS(),
webRTCStar,
wrtcStar,
wsStar
],
connection: {
@ -55,7 +55,7 @@ class Node extends libp2p {
}
if (options.webRTCStar) {
modules.discovery.push(webRTCStar.discovery)
modules.discovery.push(wrtcStar.discovery)
}
if (options.wsStar) {