ConsenSysMesh / ConsenSysMesh/hooked-web3-provider
Support for TestRPC.provider()
- Dominant language
- JavaScript
- Stars
- 78
- Forks
- 52
- PR merge metrics
- No merged PRs in 30d
Description
I'd like to run my tests using an eth-lightwallet keystore and hooked-web3-provider.
This is working great with TestRPC if the transactions are sent over HTTP, but using `TestRPC.provider()` fails if I try to implement HookedWeb3provider (which seems to assume a HTTP `host`).
I was hoping to do something generic like this, that supports both HTTP hosts and `TestRPC.provider()`
```
// create the provider for web3 transactions using ks
const hookedProvider = new HookedWeb3Provider({
...web3.currentProvider,
transaction_signer: keystore,
});
// update the web3 instance to use our new provider
web3.setProvider(hookedProvider);
```
However, it fails with:
```
Error: Invalid JSON RPC response: Error: connect ECONNREFUSED 127.0.0.1:8545
```
Happy to help with a PR this is within the scope of hooked-web3-provider. Is it?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.