Source code as reference, for the blog published by BlockApex on "Unit Testing FunC Smart Contracts"
contracts
- source code of all the smart contracts of the project and their dependencies.wrappers
- wrapper classes (implementingContract
from ton-core) for the contracts, including any [de]serialization primitives and compilation functions.tests
- tests for the contracts.
You can run the test using npm test
after installing dependencies using npm i
.
The tests are written in a given when then
structure. For optimum understanding follow the blog to write these in a TDD fashion.