update tests

This commit is contained in:
Iuri Matias 2017-12-30 17:07:13 -05:00
parent 11af38268b
commit 3e1f16c673
4 changed files with 16 additions and 5 deletions

View File

@ -208,8 +208,8 @@ class Engine {
}); });
} }
libraryManagerService(options) { libraryManagerService(_options) {
let libraryManager = new LibraryManager({ this.libraryManager = new LibraryManager({
plugins: this.plugins, plugins: this.plugins,
config: this.config config: this.config
}); });

View File

@ -30,7 +30,7 @@ Plugins.prototype.listPlugins = function() {
// for services that act as a plugin but have core functionality // for services that act as a plugin but have core functionality
Plugins.prototype.createPlugin = function(pluginName, pluginConfig) { Plugins.prototype.createPlugin = function(pluginName, pluginConfig) {
let plugin = {}; let plugin = {};
let pluginPath = undefined; let pluginPath = false;
var pluginWrapper = new Plugin({name: pluginName, pluginModule: plugin, pluginConfig: pluginConfig, logger: this.logger, pluginPath: pluginPath, interceptLogs: this.interceptLogs, events: this.events, config: this.config, isInternal: true}); var pluginWrapper = new Plugin({name: pluginName, pluginModule: plugin, pluginConfig: pluginConfig, logger: this.logger, pluginPath: pluginPath, interceptLogs: this.interceptLogs, events: this.events, config: this.config, isInternal: true});
this.plugins.push(pluginWrapper); this.plugins.push(pluginWrapper);
return pluginWrapper; return pluginWrapper;

View File

@ -57,6 +57,7 @@ Test.prototype.deployAll = function(contractsConfig, cb) {
}, },
function startServices(callback) { function startServices(callback) {
//{abiType: 'contracts', embarkJS: false} //{abiType: 'contracts', embarkJS: false}
self.engine.startService("libraryManager");
self.engine.startService("codeGenerator"); self.engine.startService("codeGenerator");
self.engine.startService("deployment", { self.engine.startService("deployment", {
web3: self.web3, web3: self.web3,

View File

@ -10,14 +10,24 @@ let readFile = function(file) {
return new File({filename: file, type: 'dapp_file', path: file}); return new File({filename: file, type: 'dapp_file', path: file});
}; };
var solcVersion = "0.4.17";
var TestEvents = {
request: (cmd, cb) => {
console.log("hello!");
cb(solcVersion)
}
};
var apiObject = { var apiObject = {
registerCompiler: function() {}, registerCompiler: function() {},
logger: new TestLogger({}) logger: new TestLogger({}),
events: TestEvents
}; };
describe('embark.Compiler', function() { describe('embark.Compiler', function() {
//let compiler = new Compiler({logger: new TestLogger({})}); //let compiler = new Compiler({logger: new TestLogger({})});
let compiler = new SolidityCompiler(apiObject, {solcVersion: '0.4.17', contractDirectories: ['app/contracts/']}); let compiler = new SolidityCompiler(apiObject, {contractDirectories: ['app/contracts/']});
describe('#compile_solidity', function() { describe('#compile_solidity', function() {
this.timeout(0); this.timeout(0);