Closed lordshashank closed 11 months ago
Hey @lordshashank looks good to me. Can we cover that with tests? Also, does it make sense to document those constants somewhere?
@vonum , I am not able to find any hardhat tests of library APIs in the repository, where should I add the tests?
all I can do is add a solidity file to test the errors here https://github.com/filecoin-project/filecoin-solidity/tree/master/contracts/v0.8/tests . Is that what you are asking, or we can make new tests folder in hardhat folder and do testing there.
Hey, the tests folder you stated is for rust tests. I would have to include solidity hardhat tests for this. There are no solidity tests in the repo. Could I make a new tests folder in ./hardhat folder for testing?
@lordshashank has asked a lot of good questions over slack and it is good that this information is widely known.
Most important questions in our discussion over slack:
5824
- CBOR partF5C03658
- function selector for get_deal_activation
00..000
- ABI encoded function parameter
We are currently working on replacing this hardcoded strings with dynamically generated ones, but it's still work in progress. For debugging purposes, you can first generate ABI part and then use https://cbor.me/ to get the full string.
resolving unconditional revert discussed in issue https://github.com/Zondax/filecoin-solidity/issues/363 . Defined error codes in new files and reverted them in actor.sol. Have defined actor errors only defined here. Tested it for deal expiration and non-existent deals. Any additional features and improvement in code is invited.