This commit is contained in:
Rostyslav Tyshko 2025-06-05 23:21:59 -04:00
parent bba2b66dbc
commit c1fd270ecf
3 changed files with 16 additions and 5 deletions

View File

@ -1,5 +1,8 @@
use serde::Serialize;
use storage::{sc_db_utils::{produce_blob_from_fit_vec, DataBlob, DataBlobChangeVariant}, SC_DATA_BLOB_SIZE};
use storage::{
sc_db_utils::{produce_blob_from_fit_vec, DataBlob, DataBlobChangeVariant},
SC_DATA_BLOB_SIZE,
};
///Creates blob list from generic serializable state
///

View File

@ -1,6 +1,6 @@
pub mod blob_utils;
pub mod cryptography;
pub mod proofs_circuits;
pub mod public_context;
pub mod traits;
pub mod transaction_payloads_tools;
pub mod public_context;
pub mod blob_utils;

View File

@ -92,7 +92,11 @@ mod tests {
static SC_DATA_BLOB_SIZE: usize = TEST_BLOB_SIZE;
fn sample_vec() -> Vec<u8> {
(0..SC_DATA_BLOB_SIZE).collect::<Vec<usize>>().iter().map(|&x| x as u8).collect()
(0..SC_DATA_BLOB_SIZE)
.collect::<Vec<usize>>()
.iter()
.map(|&x| x as u8)
.collect()
}
fn sample_data_blob() -> DataBlob {
@ -124,7 +128,11 @@ mod tests {
let variants = vec![
DataBlobChangeVariant::Created { id: 1, blob: blob1 },
DataBlobChangeVariant::Modified { id: 2, blob_old: blob1, blob_new: blob2 },
DataBlobChangeVariant::Modified {
id: 2,
blob_old: blob1,
blob_new: blob2,
},
DataBlobChangeVariant::Deleted { id: 3 },
];