diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-03-05 11:05:26 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-03-12 10:37:27 +0800 |
commit | 13299158d1e22d1af1cd36434fc403a74743ecb1 (patch) | |
tree | 9b35435c6f8641d2dc3d7bfd530c7c4f040a1f51 /packages/dev-utils/test/blockchain_lifecycle_test.ts | |
parent | a6571b09d2087ffb9a4860c0db3d7344321fe2c3 (diff) | |
download | dexon-sol-tools-13299158d1e22d1af1cd36434fc403a74743ecb1.tar.gz dexon-sol-tools-13299158d1e22d1af1cd36434fc403a74743ecb1.tar.zst dexon-sol-tools-13299158d1e22d1af1cd36434fc403a74743ecb1.zip |
Add sol-cover implementation
Diffstat (limited to 'packages/dev-utils/test/blockchain_lifecycle_test.ts')
-rw-r--r-- | packages/dev-utils/test/blockchain_lifecycle_test.ts | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/packages/dev-utils/test/blockchain_lifecycle_test.ts b/packages/dev-utils/test/blockchain_lifecycle_test.ts index 4fdc53c87..5ed67e012 100644 --- a/packages/dev-utils/test/blockchain_lifecycle_test.ts +++ b/packages/dev-utils/test/blockchain_lifecycle_test.ts @@ -3,20 +3,19 @@ import { Web3Wrapper } from '@0xproject/web3-wrapper'; import * as chai from 'chai'; import 'mocha'; -import { BlockchainLifecycle, RPC, web3Factory } from '../src'; +import { BlockchainLifecycle, web3Factory } from '../src'; const expect = chai.expect; describe('BlockchainLifecycle tests', () => { - const web3 = web3Factory.create(); - const web3Wrapper = new Web3Wrapper(web3.currentProvider); - const rpc = new RPC(); - const blockchainLifecycle = new BlockchainLifecycle(); + const web3Provider = web3Factory.getRpcProvider(); + const web3Wrapper = new Web3Wrapper(web3Provider); + const blockchainLifecycle = new BlockchainLifecycle(web3Wrapper); describe('#startAsync/revertAsync', () => { it('reverts changes in between', async () => { const blockNumberBefore = await web3Wrapper.getBlockNumberAsync(); await blockchainLifecycle.startAsync(); - await rpc.mineBlockAsync(); + await web3Wrapper.mineBlockAsync(); const blockNumberAfter = await web3Wrapper.getBlockNumberAsync(); expect(blockNumberAfter).to.be.equal(blockNumberBefore + 1); await blockchainLifecycle.revertAsync(); |