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

added coverall #10

Merged
merged 2 commits into from
Aug 12, 2024
Merged
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
39 changes: 18 additions & 21 deletions .github/workflows/test-bridge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ jobs:
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1

- name: Install tarpauline
run: |
cargo install cargo-tarpaulin

- name: Run anvil
run: |
anvil </dev/null &>/dev/null &
Expand All @@ -39,24 +35,25 @@ jobs:
echo "Running madara...."
./run_madara.sh

- name: Check if secret is accessible
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- uses: taiki-e/install-action@cargo-llvm-cov
- uses: taiki-e/install-action@nextest

- name: Clean workspace
run: |
if [ -n "CODECOV_TOKEN" ]; then
echo "Secret is accessible"
else
echo "Secret is not accessible"
exit 1
fi

- name: Run tests
cargo llvm-cov clean --workspace

- name: Run llvm-cov
run: |
echo "Running test...."
cargo tarpaulin --out Xml
sleep 5 # sleeping for few secs to ensure the coverage file is generated.
cargo llvm-cov nextest --release --lcov --output-path lcov.info

- name: Coveralls
uses: coverallsapp/github-action@v2
with:
files: lcov.info
debug: true

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
- name: Upload coverage report to Coveralls
uses: coverallsapp/github-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: lcov.info
debug: true
Loading