HomePhabricator

[chronik] Add assert_status_code_eq! macro to bitcoinsuite-chronik-client

Description

[chronik] Add assert_status_code_eq! macro to bitcoinsuite-chronik-client

Summary: Created an assert_status_code_eq! to extract the status_code of forced errors and then compare and panic if the expressions don't match. This was implemented to reduce the boilerplate of previously downcasting every error manually.

Test Plan:
Please set BUILD_DIR env to export BUILD_DIR="/path/to/build_dir
UNIX: ./contrib/teamcity/build-configurations.py build-bitcoinsuite-chronik-client
cargo test --nocapture

Reviewers: O1 Bitcoin ABC, #bitcoin_abc, Fabien

Reviewed By: O1 Bitcoin ABC, #bitcoin_abc, Fabien

Subscribers: Fabien

Differential Revision: https://reviews.bitcoinabc.org/D17784

Details

Provenance
hazzarustAuthored on Mar 12 2025, 13:58
hazzarustPushed on Mar 13 2025, 13:29
Reviewer
Restricted Owners Package
Differential Revision
D17784: [chronik] Add assert_status_code_eq! macro to bitcoinsuite-chronik-client
Parents
rABC5d218549c5d2: [electrum] freeze UTXOs that may contain ALP tokens
Branches
Unknown
Tags
Unknown