aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contracts/scripts/testrpc.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/contracts/scripts/testrpc.ts')
-rw-r--r--packages/contracts/scripts/testrpc.ts44
1 files changed, 0 insertions, 44 deletions
diff --git a/packages/contracts/scripts/testrpc.ts b/packages/contracts/scripts/testrpc.ts
deleted file mode 100644
index 347673b90..000000000
--- a/packages/contracts/scripts/testrpc.ts
+++ /dev/null
@@ -1,44 +0,0 @@
-import * as testrpc from 'ganache-cli';
-import * as _ from 'lodash';
-
-import { constants } from '../src/utils/constants';
-import { utils } from '../src/utils/utils';
-
-const opts = {
- accounts: constants.TESTRPC_ACCOUNTS,
- logger: console,
-};
-
-const server = testrpc.server(opts);
-
-server.listen(constants.TESTRPC_PORT, (err: any, result: any) => {
- if (err) {
- utils.consoleLog(err);
- return;
- }
-
- const state = result ? result : server.provider.manager.state;
-
- utils.consoleLog('');
- utils.consoleLog('Available Accounts');
- utils.consoleLog('==================');
-
- const accounts = state.accounts;
- const addresses = _.keys(accounts);
-
- _.forEach(addresses, (address, index) => {
- const line = `(${index}) ${address}`;
- utils.consoleLog(line);
- });
-
- utils.consoleLog('');
- utils.consoleLog('Private Keys');
- utils.consoleLog('==================');
-
- _.forEach(addresses, (address, index) => {
- utils.consoleLog(`(${index}) ${accounts[address].secretKey.toString('hex')}`);
- });
-
- utils.consoleLog('');
- utils.consoleLog('Listening on localhost:' + constants.TESTRPC_PORT);
-});