If you use truffle for a while, you gradually deplete all your ether from the default account. Now truffle is defunct. How do I top-up the ether?
Note I think truffle uses testrpc in the default when you run truffle test
or truffle develop
. But I don't know how to take advantage of this, and can't find where testrpc is installed.
Clarifications added after initial post:
Truffle starts testrpc internally when you run truffle test
, so I can't provide parameters to testrpc. Truffle/testrpc save the ether balances from run to run, so that the ether balance for accounts[0]
is continuously depleted over time. I have been constantly replenishing the ethers in accounts[0]
by transferring ether manually from higher numbered accounts in the truffle develop
console. Also, I can't find where testrpc is installed so I can't run it manually. Additionally, I can't figure out how truffle runs testrpc, though I have looked in the truffle executable file (/usr/local/bin/truffle on my computer).
Solution:
Turns out my problem was I had an instance of truffle develop
running in another tab. That is why the ether balances were continuously depleting. Oops!