fixed various test problems

This commit is contained in:
Manuel Araoz 2014-02-18 13:22:27 -03:00
parent 0096238004
commit 1dcd941331
2 changed files with 4 additions and 1 deletions

View File

@ -18,6 +18,7 @@ module.exports.Transaction = require('./Transaction');
module.exports.Peer = require('./Peer');
module.exports.Block = require('./Block');
module.exports.Connection = require('./Connection');
module.exports.ScriptInterpreter = require('./ScriptInterpreter');
if (typeof process.versions === 'undefined') {

View File

@ -7,6 +7,7 @@ var should = chai.should();
var ConnectionModule = bitcore.Connection;
var Connection;
var nop = function() {};
describe('Connection', function() {
it('should initialze the main object', function() {
@ -17,7 +18,8 @@ describe('Connection', function() {
should.exist(Connection);
});
it('should be able to create instance', function() {
var mSocket, mPeer;
var mSocket = {server: null, addListener: nop},
mPeer;
var c = new Connection(mSocket, mPeer);
should.exist(c);
});