smartcontractkit / chainlink-automation-templates

Real-world sample projects using Chainlink Automation

Home Page:https://automation.chainlink-demo.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use mocking library

imollov opened this issue · comments

There are 2 problems to use defi-wonderland/smock for this project:

  1. Smock can't mock abstract contracts. The only non mock contract in this project is an abstract contract so it can't be mocked or tested directly.

  2. The functions which the mock contract implement and need to be mocked are internal. Smock doesn't support mocking internal functions yet. It's planned for the next release if they rise enough for future support of the project. The comment is from January 2022 but it's still not implemented.

https://twitter.com/0xGorillaDev/status/1478707671880634368

The internal function functionality is not implemented in the last dev version, so probably we can't expect it to be ready soon.