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

Chore: fix coverage summary and more tests #9

Merged
merged 19 commits into from
May 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,5 @@ jobs:
- name: Run foundry fuzzing
run: FOUNDRY_PROFILE=ci_fuzz forge test -vv

# - name: Run foundry coverage
# run: FOUNDRY_PROFILE=coverage forge coverage --report summary
- name: Run foundry coverage
run: FOUNDRY_PROFILE=coverage forge coverage --report summary
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,7 @@ docs/

# Dotenv file
.env

# coverage
lcov.info
coverage
1 change: 1 addition & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
[submodule "lib/euler-vault-kit"]
path = lib/euler-vault-kit
url = https://github.com/euler-xyz/euler-vault-kit

36 changes: 36 additions & 0 deletions coverage.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Make sure this script is executable. On Unix based systems, run "chmod +x coverage.sh".
# To run this script, type "./coverage.sh".

#!/bin/bash

set -e # exit on error

# check if lcov is installed, if not, execute installation
if ! command -v lcov &>/dev/null; then
echo "lcov is not installed. Installing..."
# check if its macos or linux.
if [ "$(uname)" == "Darwin" ]; then
brew install lcov

else
sudo apt-get install lcov
fi
fi
lcov --version

# generates lcov.info
FOUNDRY_PROFILE=coverage forge coverage --report lcov

# Generate summary
lcov \
--rc branch_coverage=1 \
--ignore-errors inconsistent \
--list lcov.info

# Open more granular breakdown in browser
genhtml \
--ignore-errors category \
--rc branch_coverage=1 \
--output-directory coverage \
lcov.info
open coverage/index.html
2 changes: 1 addition & 1 deletion lib/ethereum-vault-connector
Submodule ethereum-vault-connector updated 39 files
+1 −1 .github/workflows/checkrules.yml
+0 −19 .solhint.json
+ audits/Euler ChainSecurity report.pdf
+ audits/Euler Omniscia report.pdf
+ audits/Euler OpenZeppelin report.pdf
+ audits/Euler Spearbit report.pdf
+ audits/Euler yAudit report (EVC + EVK + Price Oracle).pdf
+ audits/Euler yAudit report (EVC).pdf
+2 −1 certora/conf/CER-1-Owner/CER-59-Owner-override.conf
+2 −1 certora/conf/CER-11-Controllers/CER-12-Controllers-number.conf
+2 −1 certora/conf/CER-15-Permit/CER-65-Permit-onBehalfOfAccount.conf
+2 −1 certora/conf/CER-2-Operator/CER-52-Operator-deauthorization.conf
+2 −1 certora/conf/CER-2-Operator/CER-68-Operator-authorization.conf
+2 −1 certora/conf/CER-27-ExecutionContext/CER-38-ExecutionContext-restored.conf
+2 −1 certora/conf/CER-44-VaultStatusCheck/CER-78-VaultStatusCheck-scheduling.conf
+2 −1 certora/conf/misc/MustRevertFunctions.conf
+1 −1 certora/harness/EthereumVaultConnectorHarness.sol
+2 −2 certora/specs/CER-11-Controllers/CER-12-Controllers-number.spec
+2 −1 certora/specs/CER-27-ExecutionContext/CER-38-ExecutionContext-restored.spec
+2 −5 certora/specs/CER-40-AccountStatusCheck/CER-41-AccountStatusCheck-OnlyOne.spec
+1 −2 certora/specs/CER-40-AccountStatusCheck/CER-42-AccountStatusCheck-NoController.spec
+2 −2 certora/specs/utils/IsLowLevelCallFunction.spec
+0 −1 certora/specs/utils/IsMustRevertFunction.spec
+14 −13 docs/specs.md
+5 −0 docs/whitepaper.md
+39 −16 src/EthereumVaultConnector.sol
+28 −1 src/Set.sol
+10 −0 src/interfaces/IEthereumVaultConnector.sol
+6 −0 src/utils/EVCUtil.sol
+2 −0 test/evc/EthereumVaultConnectorHarness.sol
+2 −0 test/evc/EthereumVaultConnectorScribble.sol
+16 −24 test/invariants/EthereumVaultConnector.t.sol
+6 −0 test/unit/EVCUtil/EVCUtil.t.sol
+30 −1 test/unit/EthereumVaultConnector/AccountAndVaultStatus.t.sol
+28 −2 test/unit/EthereumVaultConnector/AccountStatus.t.sol
+16 −0 test/unit/EthereumVaultConnector/POC.t.sol
+5 −4 test/unit/EthereumVaultConnector/Receive.t.sol
+6 −0 test/unit/Set/Set.t.sol
+30 −4 test/utils/mocks/Vault.sol
2 changes: 1 addition & 1 deletion lib/euler-vault-kit
Submodule euler-vault-kit updated 172 files
12 changes: 0 additions & 12 deletions script/Counter.s.sol

This file was deleted.

Loading
Loading