mirror of
https://github.com/arnaucube/poulpy.git
synced 2026-02-10 13:16:44 +01:00
Added more serialization tests + generalize methods to any n
This commit is contained in:
15
core/src/lwe/tests/generic_serialization.rs
Normal file
15
core/src/lwe/tests/generic_serialization.rs
Normal file
@@ -0,0 +1,15 @@
|
||||
use backend::hal::tests::serialization::test_reader_writer_interface;
|
||||
|
||||
use crate::{LWECiphertext, LWECiphertextCompressed};
|
||||
|
||||
#[test]
|
||||
fn lwe_serialization() {
|
||||
let original: LWECiphertext<Vec<u8>> = LWECiphertext::alloc(771, 12, 54);
|
||||
test_reader_writer_interface(original);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn lwe_serialization_compressed() {
|
||||
let original: LWECiphertextCompressed<Vec<u8>> = LWECiphertextCompressed::alloc(12, 54);
|
||||
test_reader_writer_interface(original);
|
||||
}
|
||||
Reference in New Issue
Block a user