To write the test cases for our contracts, we will need to install some dependencies. We will use the chai test framework to write tests in JavaScript.Â
- To install the chai test framework, execute the following command:
$ npm install chai
- Next, we install the openzeppelin-test-helpers package. This package is built by OpenZeppelin and is used in writing the test cases. The package has some helper utilities that will be required while writing test cases for our project.
To install the OpenZeppelin Test Helpers package, execute the following command:
$ npm install openzeppelin-test-helpers
In this project, we wrote two test files for our contracts. These files are present under the project's test folder:
- MSTToken.test.js: This file contains test cases for the MSTToken contract.
- MSTCrowdsale.test.js: This file contains test...