Skip to content

Commit

Permalink
Merge pull request #292 from Shourya742/2024-11-fix-ci
Browse files Browse the repository at this point in the history
ci fix
  • Loading branch information
mojoX911 authored Nov 6, 2024
2 parents eaf8d34 + 8840198 commit 2f73f8c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 23 deletions.
33 changes: 12 additions & 21 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,33 +17,24 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Set default toolchain
run: rustup default nightly

- name: Set profile
run: rustup set profile minimal

- name: Install grcov
run: cargo install grcov --force --version 0.8.2

- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true

- name: Install dependencies on macOS
if: matrix.os == 'macos-latest'
run: brew install automake libtool zeromq

- name: Run cargo test
env:
CARGO_INCREMENTAL: '0'
RUSTFLAGS: '-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off'
RUSTDOCFLAGS: '-Zprofile -Ccodegen-units=1 -Cinline-threshold=0 -Clink-dead-code -Coverflow-checks=off'
run: cargo test --features=integration-test -- --nocapture
- name: Install cargo-tarpaulin
run: cargo install cargo-tarpaulin

- id: coverage
name: Generate coverage
uses: actions-rs/grcov@v0.1.5
- name: Run cargo-tarpaulin
run: cargo tarpaulin --timeout 1900 --out Xml --output-dir "./coverage/reports/" --features integration-test -- --nocapture

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ${{ steps.coverage.outputs.report }}
directory: ./coverage/reports/
file: ./coverage/reports/cobertura.xml
2 changes: 1 addition & 1 deletion codecov.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ coverage:
project:
default:
target: auto
threshold: 1%
threshold: 10%
base: auto
informational: false
patch:
Expand Down
2 changes: 1 addition & 1 deletion src/wallet/fidelity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ impl Wallet {
(info.height, info.time as u64)
};
// Estimated locktime from block height = [current-time + (maturity-height - block-count) * 10 * 60] sec
tip_time + (((blocks.to_consensus_u32() - (tip_height as u32)) * 10 * 60) as u64)
tip_time + ((blocks.to_consensus_u32() as u64 - tip_height as u64) * 10 * 60)
}
LockTime::Seconds(sec) => sec.to_consensus_u32() as u64,
};
Expand Down

0 comments on commit 2f73f8c

Please sign in to comment.