()
| 222 | |
| 223 | #[test] |
| 224 | fn test_borsh_serialization() { |
| 225 | let original_tx = Transaction { |
| 226 | version: Version(1), |
| 227 | lock_time: LockTime::from_consensus(0), |
| 228 | input: vec![], |
| 229 | output: vec![], |
| 230 | }; |
| 231 | let bridge_tx = CircuitTransaction(original_tx); |
| 232 | |
| 233 | // Serialize |
| 234 | let serialized = borsh::to_vec(&bridge_tx).unwrap(); |
| 235 | |
| 236 | // Deserialize |
| 237 | let deserialized: CircuitTransaction = borsh::from_slice(&serialized).unwrap(); |
| 238 | |
| 239 | assert_eq!(bridge_tx, deserialized); |
| 240 | assert_eq!(bridge_tx.txid(), deserialized.txid()); |
| 241 | } |
| 242 | |
| 243 | #[test] |
| 244 | fn test_deref_traits() { |
nothing calls this directly
no test coverage detected