Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Update]: Improve coverage #293

Open
wants to merge 52 commits into
base: main
Choose a base branch
from
Open

[Update]: Improve coverage #293

wants to merge 52 commits into from

Conversation

Mohsen-T
Copy link
Contributor

  • refactored the skip files array generation process in the .solcover.js
  • solidity-coverage does not offer native support *.sol.
  • implemented a programmatic function to dynamically generate the skip files array based on folder names.
  • defined the depth of coverage

mtabasco and others added 30 commits November 10, 2023 14:25
…res (#276)

* feat: updated validators & operators management using ssv-keys
…pdating) (#285)

* feat: added trigger for compilation in tasks
…perators

[Review] Balance calculation when operators will be removed
* v1.0.2 deployment metadata
* bulk validator registration
mtabasco and others added 17 commits January 16, 2024 02:25
Enhanced test coverage by incorporating additional test cases to address previously overlooked scenarios
- refactored the skip files array generation process in the .solcover.js
- solidity-coverage does not offer native support *.sol.
- implemented a programmatic function to dynamically generate the skip files array based on folder names.
- defined the depth of coverage
@mtabasco
Copy link
Collaborator

image @Mohsen-T to reach this point, create a test in `test/validators/remove.ts` trying to remove an existing validator (`publicKey` correct) with the wrong parameters (`msg.sender` or `operatorIds`)

@mtabasco
Copy link
Collaborator

image

@Mohsen-T please create a test to fire the revert PublicKeysSharesLengthMismatch

@mtabasco
Copy link
Collaborator

image

In ClusterLib.sol seems this line is skipped.
The test Register validator in a new cluster with incorrect input data passes the wrong cluster data. Maybe you can pass specifically that parameter wrong to include that line in the coverage? thanks

@mtabasco
Copy link
Collaborator

mtabasco commented Feb 14, 2024

image image

In OperatorsLib.sol, we haven't tested ExceedValidatorLimit error😱

@mtabasco
Copy link
Collaborator

mtabasco commented Feb 14, 2024

image ProtocolLib.sol Please test the `MaxValueExceeded` error

@mtabasco
Copy link
Collaborator

mtabasco commented Feb 14, 2024

image image

ValidatorLib.sol
Please test InvalidOperatorIdsLength and InvalidPublicKeyLength

@mtabasco
Copy link
Collaborator

image

please skip contracts/upgrades from the coverage test

Copy link
Collaborator

@mtabasco mtabasco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see the attached comments. thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants