2018-06-07 20:14:42 +00:00
|
|
|
/*global contract, config, it*/
|
2018-06-01 17:44:30 +00:00
|
|
|
const assert = require('assert');
|
2018-06-07 20:14:42 +00:00
|
|
|
const Test2 = require('Embark/contracts/Test2');
|
2018-01-05 20:10:47 +00:00
|
|
|
|
2018-06-01 17:44:30 +00:00
|
|
|
config({
|
|
|
|
contracts: {
|
2019-08-30 20:50:20 +00:00
|
|
|
deploy: {
|
|
|
|
"Test2": {},
|
|
|
|
"ZAMyLib": {},
|
|
|
|
"ZAMyLib2": {
|
|
|
|
"deploy": true
|
|
|
|
}
|
2018-06-01 17:44:30 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
2017-12-27 13:37:39 +00:00
|
|
|
|
2018-06-01 17:44:30 +00:00
|
|
|
contract("Test", function() {
|
2018-04-17 18:48:31 +00:00
|
|
|
it("should call library correctly", async function() {
|
|
|
|
let result = await Test2.methods.testAdd().call();
|
2018-06-01 17:44:30 +00:00
|
|
|
assert.strictEqual(parseInt(result, 10), 3);
|
2017-12-27 13:37:39 +00:00
|
|
|
});
|
|
|
|
|
|
|
|
});
|