Commit f5e12c63 authored by aniket-engg's avatar aniket-engg Committed by Aniket

devdoc & type

parent 82a999f6
import async from 'async'
var remixLib = require('remix-lib')
const remixLib = require('remix-lib')
import Web3 from 'web3';
import { compilationInterface } from 'types';
export function deployAll(compileResult: object, web3: Web3, isAgain: boolean, callback) {
/**
* @dev Deploy all contracts from compilation result
* @param compileResult compilation result
* @param web3 web3 object
* @param isAgain If true, try deployment with gas double of estimation (used for Out-of-gas error only)
* @param callback Callback
*/
export function deployAll(compileResult: compilationInterface, web3: Web3, isAgain: boolean, callback) {
let compiledObject = {}
let contracts = {}
let accounts: string[] = []
......
......@@ -6,7 +6,7 @@ import { Provider } from 'remix-simulator'
import { compileFileOrFiles } from '../dist/compiler'
import { deployAll } from '../dist/deployer'
import { runTest } from '../dist/index'
import { runTest, compilationInterface } from '../dist/index'
import { ResultsInterface, TestCbInterface, ResultCbInterface } from '../dist/index'
// deepEqualExcluding allows us to exclude specific keys whose values vary.
......@@ -60,7 +60,7 @@ async function compileAndDeploy(filename: string, callback: Function) {
function compile(next: Function): void {
compileFileOrFiles(filename, false, { accounts }, next)
},
function deployAllContracts(compilationResult: object, asts, next: Function): void {
function deployAllContracts(compilationResult: compilationInterface, asts, next: Function): void {
for(const filename in asts) {
if(filename.endsWith('_test.sol'))
sourceASTs[filename] = asts[filename].ast
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment