defi-wonderland / smock

The Solidity mocking library
MIT License
321 stars 39 forks source link

Unable to mock the functions using Smock.mock #179

Open adi274 opened 1 year ago

adi274 commented 1 year ago

Describe the bug

I tried mocking a function but it's not working. Here is the gist containing the tests that I trying to run.

I tried mocking several functions

Expected behavior The above mentioned functions should be mocked as per the requirements, but the actual implementations of the contract is running.

System Specs:

cleivson commented 1 year ago

I'm having problem. When calling the mocked function for the first time it runs the actual contract code. On the second time forward it calls the fake function