What changed, and why it matters
This commit only updates internal test code to stop using two recently-renamed type names (`Height` and `Time`) and instead use their new names (`NumberOfBlocks` and `NumberOf512Seconds`). It does not change any production code, behavior, or data formats, and it is not a security fix.
No security action needed. Treat as a routine test-maintenance commit.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch modifies bitcoin/tests/serde.rs, replacing deprecated aliases relative::Height and relative::Time with relative::NumberOfBlocks and relative::NumberOf512Seconds in two serde regression tests. The serialized bytes and test assertions remain unchanged. No library logic, parsing, validation, or consensus code is touched.
Changed components
bitcoin/tests/serde.rsInspect captured patch +4 / −2
diff --git a/bitcoin/tests/serde.rs b/bitcoin/tests/serde.rs
index 071762c6..05a1a32a 100644
--- a/bitcoin/tests/serde.rs
+++ b/bitcoin/tests/serde.rs
@@ -55,7 +55,7 @@ fn serde_regression_absolute_lock_time_time() {
#[test]
fn serde_regression_relative_lock_time_height() {
- let t = relative::LockTime::from(relative::Height::from(0xCAFE_u16));
+ let t = relative::LockTime::from(relative::NumberOfBlocks::from(0xCAFE_u16));
let got = serialize(&t).unwrap();
let want = include_bytes!("data/serde/relative_lock_time_blocks_bincode") as &[_];
@@ -64,7 +64,9 @@ fn serde_regression_relative_lock_time_height() {
#[test]
fn serde_regression_relative_lock_time_time() {
- let t = relative::LockTime::from(relative::Time::from_512_second_intervals(0xFACE_u16));
+ let t = relative::LockTime::from(relative::NumberOf512Seconds::from_512_second_intervals(
+ 0xFACE_u16,
+ ));
let got = serialize(&t).unwrap();
let want = include_bytes!("data/serde/relative_lock_time_seconds_bincode") as &[_];
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.