Created
April 23, 2020 14:38
-
-
Save marekkirejczyk/26760be05f2e559ed45e66da1285519c to your computer and use it in GitHub Desktop.
Mocking Smart Contracts with Waffle
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const mockContract = await deployMockContract(wallet, Contract.interface); | |
await mockContract.mock.add.returns(1); | |
await mockContract.mock.mul.withArgs(2, 2).returns(4); | |
await mockContract.mock.div.withArgs(3, 0).reverts(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment