fn transaction_receipt_bytes() {
        let original = TransactionReceipt {
            state_changes: vec![
                StateChange::Set {
                    key: ADDRESS.to_string(),
                    value: BYTES1.to_vec(),
                },
                StateChange::Delete {
                    key: ADDRESS.to_string(),
                },
            ],
            events: vec![make_event_1(), make_event_2()],
            data: vec![BYTES1.to_vec(), BYTES2.to_vec(), BYTES3.to_vec()],
            transaction_id: TRANSACTION_ID.to_string(),
        };

        let receipt_bytes = original.clone().into_bytes().unwrap();
        let receipt = TransactionReceipt::from_bytes(&receipt_bytes).unwrap();

        check_transaction_receipt(receipt.clone());
        assert_eq!(original.transaction_id, receipt.transaction_id);
    }
// test that the transaction receipts can be converted into bytes and back correctly
test that the transaction receipts can be converted into bytes and back correctly
test that the transaction receipts can be converted into bytes and back correctly
fn transaction_receipt_bytes() {
        let original = TransactionReceipt {
            state_changes: vec![
                StateChange::Set {
                    key: ADDRESS.to_string(),
                    value: BYTES1.to_vec(),
                },
                StateChange::Delete {
                    key: ADDRESS.to_string(),
                },
            ],
            events: vec![make_event_1(), make_event_2()],
            data: vec![BYTES1.to_vec(), BYTES2.to_vec(), BYTES3.to_vec()],
            transaction_id: TRANSACTION_ID.to_string(),
        };
        let receipt_bytes = original.clone().into_bytes().unwrap();
        let receipt = TransactionReceipt::from_bytes(&receipt_bytes).unwrap();
        check_transaction_receipt(receipt.clone());
        assert_eq!(original.transaction_id, receipt.transaction_id);
    }
fn transaction_receipt_bytes ( ) { let original = TransactionReceipt { state_changes : vec ! [ StateChange Set { key ADDRESS to_string ( ) value BYTES1 to_vec ( ) } StateChange Delete { key ADDRESS to_string ( ) } ] , events : vec ! [ make_event_1 ( ) make_event_2 ( ) ] , data : vec ! [ BYTES1 to_vec ( ) BYTES2 to_vec ( ) BYTES3 to_vec ( ) ] , transaction_id : TRANSACTION_ID . to_string ( ) , } ; let receipt_bytes = original . clone ( ) . into_bytes ( ) . unwrap ( ) ; let receipt = TransactionReceipt :: from_bytes ( & receipt_bytes ) . unwrap ( ) ; check_transaction_receipt ( receipt . clone ( ) ) ; assert_eq ! ( original transaction_id receipt transaction_id ) ; }
test that the transaction receipts can be converted into bytes and back correctly
test that the transaction receipts can be converted into bytes and back correctly