Fix artifacts path

This commit is contained in:
Amir Bandeali
2018-02-05 16:25:52 -08:00
parent 6cda67df10
commit 218876ac19
4 changed files with 13 additions and 13 deletions

View File

@@ -99,7 +99,7 @@ for (const abiFileName of abiFileNames) {
} else if (!_.isUndefined(parsedContent.abi)) { } else if (!_.isUndefined(parsedContent.abi)) {
ABI = parsedContent.abi; // Truffle artifact ABI = parsedContent.abi; // Truffle artifact
} else if (!_.isUndefined(parsedContent.networks) && !_.isUndefined(parsedContent.networks[args.networkId])) { } else if (!_.isUndefined(parsedContent.networks) && !_.isUndefined(parsedContent.networks[args.networkId])) {
ABI = parsedContent.networks[args.networkId]; // 0x contracts package artifact ABI = parsedContent.networks[args.networkId].abi; // 0x contracts package artifact
} }
if (_.isUndefined(ABI)) { if (_.isUndefined(ABI)) {
utils.log(`${chalk.red(`ABI not found in ${abiFileName}.`)}`); utils.log(`${chalk.red(`ABI not found in ${abiFileName}.`)}`);

View File

@@ -10,7 +10,7 @@
"scripts": { "scripts": {
"build:watch": "tsc -w", "build:watch": "tsc -w",
"prebuild": "run-s clean copy_artifacts", "prebuild": "run-s clean copy_artifacts",
"copy_artifacts": "copyfiles './artifacts/**/*' ./lib", "copy_artifacts": "copyfiles './src/artifacts/**/*' ./lib",
"build": "tsc", "build": "tsc",
"test": "run-s compile build run_mocha", "test": "run-s compile build run_mocha",
"run_mocha": "mocha 'lib/test/**/*.js' --timeout 10000 --bail --exit", "run_mocha": "mocha 'lib/test/**/*.js' --timeout 10000 --bail --exit",

View File

@@ -5,7 +5,7 @@ import * as path from 'path';
import { constants } from '../../util/constants'; import { constants } from '../../util/constants';
const deployerOpts = { const deployerOpts = {
artifactsDir: path.resolve('artifacts'), artifactsDir: path.resolve('src', 'artifacts'),
jsonrpcPort: devConstants.RPC_PORT, jsonrpcPort: devConstants.RPC_PORT,
networkId: constants.TESTRPC_NETWORK_ID, networkId: constants.TESTRPC_NETWORK_ID,
defaults: { defaults: {

View File

@@ -1,13 +1,13 @@
import * as DummyTokenArtifact from '../artifacts/DummyToken.json'; import * as DummyTokenArtifact from '../src/artifacts/DummyToken.json';
import * as ExchangeArtifact from '../artifacts/Exchange.json'; import * as ExchangeArtifact from '../src/artifacts/Exchange.json';
import * as MaliciousTokenArtifact from '../artifacts/MaliciousToken.json'; import * as MaliciousTokenArtifact from '../src/artifacts/MaliciousToken.json';
import * as MultiSigWalletWithTimeLockArtifact from '../artifacts/MultiSigWalletWithTimeLock.json'; import * as MultiSigWalletWithTimeLockArtifact from '../src/artifacts/MultiSigWalletWithTimeLock.json';
import * as MultiSigWalletWithTimeLockExceptRemoveAuthorizedAddressArtifact from '../artifacts/MultiSigWalletWithTimeLockExceptRemoveAuthorizedAddress.json'; import * as MultiSigWalletWithTimeLockExceptRemoveAuthorizedAddressArtifact from '../src/artifacts/MultiSigWalletWithTimeLockExceptRemoveAuthorizedAddress.json';
import * as TokenArtifact from '../artifacts/Token.json'; import * as TokenArtifact from '../src/artifacts/Token.json';
import * as TokenRegistryArtifact from '../artifacts/TokenRegistry.json'; import * as TokenRegistryArtifact from '../src/artifacts/TokenRegistry.json';
import * as TokenTransferProxyArtifact from '../artifacts/TokenTransferProxy.json'; import * as TokenTransferProxyArtifact from '../src/artifacts/TokenTransferProxy.json';
import * as EtherTokenArtifact from '../artifacts/WETH9.json'; import * as EtherTokenArtifact from '../src/artifacts/WETH9.json';
import * as ZRXArtifact from '../artifacts/ZRXToken.json'; import * as ZRXArtifact from '../src/artifacts/ZRXToken.json';
import { Artifact } from './types'; import { Artifact } from './types';