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

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
dignifiedquire committed Jul 4, 2016
1 parent 06afc49 commit 10c73da
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/dial.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ module.exports = function dial (swarm) {
if (err) {
return cb(err)
}

console.log('dial: %s', id.toB58String())
cb(null, secio.create(id, conn))
})
})
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ function Swarm (peerInfo) {
if (this.encrypt === false) {
return protocolMuxer(this.protocols, conn)
}

console.log('handle: %s', this._peerInfo.id.toB58String())
const secure = secio.create(this._peerInfo.id, conn)
protocolMuxer(this.protocols, secure)
})
Expand Down
8 changes: 4 additions & 4 deletions test/06-conn-upgrade-secio.node.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const multiplex = require('libp2p-spdy')

const Swarm = require('../src')

describe.skip('secio conn upgrade (on TCP)', function () {
describe.only('secio conn upgrade (on TCP)', function () {
this.timeout(60 * 1000)

var swarmA
Expand Down Expand Up @@ -86,7 +86,7 @@ describe.skip('secio conn upgrade (on TCP)', function () {
})
})

it.skip('dial to warm conn', (done) => {
it('dial to warm conn', (done) => {
swarmB.dial(peerA, (err) => {
expect(err).to.not.exist
expect(Object.keys(swarmB.conns).length).to.equal(0)
Expand All @@ -95,7 +95,7 @@ describe.skip('secio conn upgrade (on TCP)', function () {
})
})

it.skip('dial on protocol, reuse warmed conn', (done) => {
it('dial on protocol, reuse warmed conn', (done) => {
swarmA.handle('/papaia/1.0.0', (conn) => {
conn.pipe(conn)
conn.on('error', (err) => { throw err })
Expand All @@ -112,7 +112,7 @@ describe.skip('secio conn upgrade (on TCP)', function () {
})
})

it.skip('enable identify to reuse incomming muxed conn', (done) => {
it('enable identify to reuse incomming muxed conn', (done) => {
swarmA.connection.reuse()
swarmC.connection.reuse()

Expand Down

0 comments on commit 10c73da

Please sign in to comment.