Is there a way to run truffle test and not recompile the solidity code each time? It takes a lot of time if i just want to play around with the javascript tests...
Thanks!
Is there a way to run truffle test and not recompile the solidity code each time? It takes a lot of time if i just want to play around with the javascript tests...
Thanks!
Since January 2020 Truffle suite has option --compile-none
With this option enabled it tests compiled contracts from build/contracts directory.
Here is how it looks like in Truffle v5.1.55:
PS D:\work\ERC20> truffle test --compile-none
Using network 'test'.
Compiling your contracts...
> Everything is up to date, there is nothing to compile.
This is a known issue with truffle. As of Nov 2018 and the latest version 4.1.14, there is no out-of-the-box solution. There is a workaround, albeit a bit messy:
Create an empty folder called migrations_null and then run your tests like this:
truffle test --migrations_directory migrations_null