@@ -6,7 +6,7 @@ use minicbor::{
66 Decode , Decoder , Encode , Encoder ,
77} ;
88
9- use crate :: { Choice , GeneralisedTx , Proof , PropId , TxBody , Uuid , Vote , VoterData } ;
9+ use crate :: { Choice , GeneralizedTx , Proof , PropId , TxBody , Uuid , Vote , VoterData } ;
1010
1111/// UUID CBOR tag <https://www.iana.org/assignments/cbor-tags/cbor-tags.xhtml/>.
1212const CBOR_UUID_TAG : u64 = 37 ;
@@ -17,22 +17,22 @@ const VOTE_LEN: u64 = 3;
1717/// `TxBody` array struct length
1818const TX_BODY_LEN : u64 = 3 ;
1919
20- /// `GeneralisedTx ` array struct length
21- const GENERALISED_TX_LEN : u64 = 1 ;
20+ /// `GeneralizedTx ` array struct length
21+ const GENERALIZED_TX_LEN : u64 = 1 ;
2222
23- impl Decode < ' _ , ( ) > for GeneralisedTx {
23+ impl Decode < ' _ , ( ) > for GeneralizedTx {
2424 fn decode ( d : & mut Decoder < ' _ > , ( ) : & mut ( ) ) -> Result < Self , minicbor:: decode:: Error > {
2525 d. array ( ) ?;
2626 let tx_body = TxBody :: decode ( d, & mut ( ) ) ?;
2727 Ok ( Self { tx_body } )
2828 }
2929}
3030
31- impl Encode < ( ) > for GeneralisedTx {
31+ impl Encode < ( ) > for GeneralizedTx {
3232 fn encode < W : minicbor:: encode:: Write > (
3333 & self , e : & mut Encoder < W > , ( ) : & mut ( ) ,
3434 ) -> Result < ( ) , minicbor:: encode:: Error < W :: Error > > {
35- e. array ( GENERALISED_TX_LEN ) ?;
35+ e. array ( GENERALIZED_TX_LEN ) ?;
3636 self . tx_body . encode ( e, & mut ( ) ) ?;
3737 Ok ( ( ) )
3838 }
@@ -231,10 +231,10 @@ mod tests {
231231 use crate :: Cbor ;
232232
233233 #[ proptest]
234- fn generalised_tx_from_bytes_to_bytes_test ( generalised_tx : GeneralisedTx ) {
235- let bytes = generalised_tx . to_bytes ( ) . unwrap ( ) ;
236- let decoded = GeneralisedTx :: from_bytes ( & bytes) . unwrap ( ) ;
237- assert_eq ! ( generalised_tx , decoded) ;
234+ fn generalized_tx_from_bytes_to_bytes_test ( generalized_tx : GeneralizedTx ) {
235+ let bytes = generalized_tx . to_bytes ( ) . unwrap ( ) ;
236+ let decoded = GeneralizedTx :: from_bytes ( & bytes) . unwrap ( ) ;
237+ assert_eq ! ( generalized_tx , decoded) ;
238238 }
239239
240240 #[ proptest]
0 commit comments