mirror of https://github.com/embarklabs/embark.git
updatests; include options
This commit is contained in:
parent
16afb4e405
commit
cd0fd94386
|
@ -43,6 +43,10 @@ module.exports = {
|
|||
//global.Embark = require("../index.js");
|
||||
//global.EmbarkSpec = global.Embark.initTests();
|
||||
|
||||
let configOptions = {};
|
||||
global.config = function(config) {
|
||||
configOptions = config;
|
||||
};
|
||||
// TODO: check how to pass the options
|
||||
//global.EmbarkSpec = new Test(options);
|
||||
global.EmbarkSpec = new Test({});
|
||||
|
@ -66,11 +70,19 @@ module.exports = {
|
|||
//global.EmbarkSpec = global.Embark.initTests();
|
||||
// TODO: check how to pass the options
|
||||
//global.EmbarkSpec = new Test(options);
|
||||
global.EmbarkSpec = new Test({});
|
||||
//global.config = function(config) {
|
||||
// console.log("running config!");
|
||||
// console.log(config.hello);
|
||||
// configOptions = config;
|
||||
//};
|
||||
|
||||
//console.log("---------");
|
||||
//console.log(configOptions);
|
||||
//console.log("---------");
|
||||
global.EmbarkSpec = new Test({simulatorOptions: configOptions});
|
||||
global.web3 = global.EmbarkSpec.web3;
|
||||
//global.contract = Mocha.describe;
|
||||
});
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -92,7 +92,8 @@ Test.prototype.deployAll = function(contractsConfig, cb) {
|
|||
}
|
||||
self.web3.eth.defaultAccount = accounts[0];
|
||||
RunCode.doEval(result, self.web3); // jshint ignore:line
|
||||
cb();
|
||||
//cb();
|
||||
cb(accounts);
|
||||
});
|
||||
});
|
||||
};
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
"commander": "^2.8.1",
|
||||
"css-loader": "^0.28.7",
|
||||
"ejs": "^2.5.7",
|
||||
"ethereumjs-testrpc": "3.9.2",
|
||||
"ethereumjs-testrpc": "^6.0.3",
|
||||
"file-loader": "^1.1.5",
|
||||
"finalhandler": "^0.5.0",
|
||||
"follow-redirects": "^1.2.4",
|
||||
|
|
|
@ -20,7 +20,7 @@ contract("AnotherStorage", function() {
|
|||
args: [2000]
|
||||
}
|
||||
};
|
||||
EmbarkSpec.deployAll(contractsConfig, done);
|
||||
EmbarkSpec.deployAll(contractsConfig, () => { done() });
|
||||
});
|
||||
|
||||
it("set SimpleStorage address", function(done) {
|
||||
|
|
|
@ -6,7 +6,7 @@ describe("SimpleStorage", function() {
|
|||
args: [100]
|
||||
}
|
||||
};
|
||||
EmbarkSpec.deployAll(contractsConfig, done);
|
||||
EmbarkSpec.deployAll(contractsConfig, () => { done() });
|
||||
});
|
||||
|
||||
it("should set constructor value", function(done) {
|
||||
|
|
|
@ -29,7 +29,7 @@ describe("Token", function() {
|
|||
]
|
||||
}
|
||||
};
|
||||
EmbarkSpec.deployAll(contractsConfig, done);
|
||||
EmbarkSpec.deployAll(contractsConfig, () => { done() });
|
||||
});
|
||||
|
||||
it("not deploy Token", function(done) {
|
||||
|
|
Loading…
Reference in New Issue