diff options
author | Steve Klebanoff <steve.klebanoff@gmail.com> | 2019-01-10 00:54:55 +0800 |
---|---|---|
committer | Steve Klebanoff <steve.klebanoff@gmail.com> | 2019-01-10 00:54:55 +0800 |
commit | fb3605026ef63ef6897010a52bf3f4c116cdf271 (patch) | |
tree | af3887e5f785e049daeaf795e0f3e4a9ad370d93 /packages/dev-utils | |
parent | 76dde294f10bb3d5c1074cd6599668bcb1cdd8ec (diff) | |
parent | 5b8c9122a292f6558c45440b053ceae52d36d495 (diff) | |
download | dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar.gz dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar.bz2 dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar.lz dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar.xz dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.tar.zst dexon-sol-tools-fb3605026ef63ef6897010a52bf3f4c116cdf271.zip |
Merge branch 'development' into feature/instant/tell-amount-available
Diffstat (limited to 'packages/dev-utils')
-rw-r--r-- | packages/dev-utils/CHANGELOG.json | 9 | ||||
-rw-r--r-- | packages/dev-utils/CHANGELOG.md | 4 | ||||
-rw-r--r-- | packages/dev-utils/package.json | 10 | ||||
-rw-r--r-- | packages/dev-utils/src/web3_factory.ts | 6 |
4 files changed, 24 insertions, 5 deletions
diff --git a/packages/dev-utils/CHANGELOG.json b/packages/dev-utils/CHANGELOG.json index b6cc74ce7..8f355466c 100644 --- a/packages/dev-utils/CHANGELOG.json +++ b/packages/dev-utils/CHANGELOG.json @@ -1,5 +1,14 @@ [ { + "timestamp": 1547040760, + "version": "1.0.22", + "changes": [ + { + "note": "Dependencies updated" + } + ] + }, + { "version": "1.0.21", "changes": [ { diff --git a/packages/dev-utils/CHANGELOG.md b/packages/dev-utils/CHANGELOG.md index 9a55e4e58..04ee860b5 100644 --- a/packages/dev-utils/CHANGELOG.md +++ b/packages/dev-utils/CHANGELOG.md @@ -5,6 +5,10 @@ Edit the package's CHANGELOG.json file only. CHANGELOG +## v1.0.22 - _January 9, 2019_ + + * Dependencies updated + ## v1.0.21 - _December 13, 2018_ * Dependencies updated diff --git a/packages/dev-utils/package.json b/packages/dev-utils/package.json index a3eb4651a..cb27ad5c5 100644 --- a/packages/dev-utils/package.json +++ b/packages/dev-utils/package.json @@ -1,6 +1,6 @@ { "name": "@0x/dev-utils", - "version": "1.0.21", + "version": "1.0.22", "engines": { "node": ">=6.12" }, @@ -41,11 +41,11 @@ "typescript": "3.0.1" }, "dependencies": { - "@0x/subproviders": "^2.1.8", - "@0x/types": "^1.4.1", + "@0x/subproviders": "^2.1.9", + "@0x/types": "^1.5.0", "@0x/typescript-typings": "^3.0.6", - "@0x/utils": "^2.0.8", - "@0x/web3-wrapper": "^3.2.1", + "@0x/utils": "^2.1.1", + "@0x/web3-wrapper": "^3.2.2", "@types/web3-provider-engine": "^14.0.0", "chai": "^4.0.1", "ethereum-types": "^1.1.4", diff --git a/packages/dev-utils/src/web3_factory.ts b/packages/dev-utils/src/web3_factory.ts index b22bcc88b..5f8981a46 100644 --- a/packages/dev-utils/src/web3_factory.ts +++ b/packages/dev-utils/src/web3_factory.ts @@ -17,6 +17,7 @@ export interface Web3Config { shouldThrowErrorsOnGanacheRPCResponse?: boolean; // default: true rpcUrl?: string; // default: localhost:8545 shouldUseFakeGasEstimate?: boolean; // default: true + ganacheDatabasePath?: string; // default: undefined, creates a tmp dir } export const web3Factory = { @@ -45,9 +46,14 @@ export const web3Factory = { const shouldThrowErrorsOnGanacheRPCResponse = _.isUndefined(config.shouldThrowErrorsOnGanacheRPCResponse) || config.shouldThrowErrorsOnGanacheRPCResponse; + if (!_.isUndefined(config.ganacheDatabasePath)) { + // Saving the snapshot to a local db. Ganache requires this directory to exist + fs.mkdirSync(config.ganacheDatabasePath); + } provider.addProvider( new GanacheSubprovider({ vmErrorsOnRPCResponse: shouldThrowErrorsOnGanacheRPCResponse, + db_path: config.ganacheDatabasePath, gasLimit: constants.GAS_LIMIT, logger, verbose: env.parseBoolean(EnvVars.VerboseGanache), |