MCPcopy Create free account
hub / github.com/PolymathNetwork/polymath-core / deploySTFactory

Function deploySTFactory

test/helpers/createInstances.js:249–271  ·  view source on GitHub ↗
(account_polymath)

Source from the content-addressed store, hash-verified

247}
248
249async function deploySTFactory(account_polymath) {
250 I_STGetter = await STGetter.new({from: account_polymath});
251 I_SecurityToken = await SecurityTokenLogic.new("", "", 0, {from: account_polymath});
252 console.log("STL - " + I_SecurityToken.address);
253 let I_DataStoreLogic = await DataStoreLogic.new({ from: account_polymath });
254 let I_DataStoreFactory = await DataStoreFactory.new(I_DataStoreLogic.address, { from: account_polymath });
255 const tokenInitBytes = {
256 name: "initialize",
257 type: "function",
258 inputs: [
259 {
260 type: "address",
261 name: "_getterDelegate"
262 }
263 ]
264 };
265 let tokenInitBytesCall = web3.eth.abi.encodeFunctionCall(tokenInitBytes, [I_STGetter.address]);
266 I_STFactory = await STFactory.new(I_PolymathRegistry.address, I_GeneralTransferManagerFactory.address, I_DataStoreFactory.address, "3.0.0", I_SecurityToken.address, tokenInitBytesCall, { from: account_polymath });
267
268 assert.notEqual(I_STFactory.address.valueOf(), "0x0000000000000000000000000000000000000000", "STFactory contract was not deployed");
269
270 return new Array(I_STFactory, I_STGetter);
271}
272
273async function deploySTR(account_polymath) {
274 I_SecurityTokenRegistry = await SecurityTokenRegistry.new({ from: account_polymath });

Callers 1

setUpPolymathNetworkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected