From a3bb4bc53b1727d0f30cd232d1e13c15f3ddd78e Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Tue, 5 Jun 2018 08:38:27 -0400 Subject: [PATCH] update tests --- test/compiler.js | 7 ++++++- test/contracts.js | 11 +++++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/test/compiler.js b/test/compiler.js index 4bc48160c..7f9a8649a 100644 --- a/test/compiler.js +++ b/test/compiler.js @@ -2,6 +2,7 @@ let SolidityCompiler = require('../lib/modules/solidity'); let TestLogger = require('../lib/tests/test_logger.js'); let File = require('../lib/core/file.js'); +let Ipc = require('../lib/core/ipc.js'); let assert = require('assert'); let readFile = function(file) { @@ -16,6 +17,10 @@ var TestEvents = { } }; +let ipcObject = new Ipc({ + ipcRole: 'none' +}); + var apiObject = { registerCompiler: function() {}, logger: new TestLogger({}), @@ -27,7 +32,7 @@ var apiObject = { describe('embark.Compiler', function() { //let compiler = new Compiler({logger: new TestLogger({})}); - let compiler = new SolidityCompiler(apiObject); + let compiler = new SolidityCompiler(apiObject, {ipc: ipcObject}); describe('#compile_solidity', function() { this.timeout(0); diff --git a/test/contracts.js b/test/contracts.js index b8452b806..9662fa8ba 100644 --- a/test/contracts.js +++ b/test/contracts.js @@ -5,6 +5,7 @@ let Logger = require('../lib/core/logger.js'); let File = require('../lib/core/file.js'); let TestLogger = require('../lib/tests/test_logger.js'); let Events = require('../lib/core/events'); +let Ipc = require('../lib/core/ipc.js'); let assert = require('assert'); //let SolidityCompiler = require('../lib/modules/solidity'); @@ -31,7 +32,10 @@ describe('embark.Contracts', function() { contractDirectories: ['app/contracts/'] } }); - plugins.loadInternalPlugin('solidity'); + let ipcObject = new Ipc({ + ipcRole: 'none' + }); + plugins.loadInternalPlugin('solidity', {ipc: ipcObject}); let compiler = new Compiler({plugins: plugins, logger: plugins.logger}); let events = new Events(); @@ -123,7 +127,10 @@ describe('embark.Contracts', function() { contractDirectories: ['app/contracts/'] } }); - plugins.loadInternalPlugin('solidity'); + let ipcObject = new Ipc({ + ipcRole: 'none' + }); + plugins.loadInternalPlugin('solidity', {ipc: ipcObject}); let compiler = new Compiler({plugins: plugins, logger: plugins.logger}); let events = new Events();