Vibe Protocol is a secure, decentralized, and privacy-focused messaging protocol. Its designed using Sodium, Base64, and other cryptographic libraries to ensure the highest level of security and privacy.
#[cfg(test)]modbase64_tests{useVibeProtocol::base64_wrapper::{encode_base64, decode_base64};#[test]fntest_encode_and_decode_base64(){let data ="vibe protocol";let encoded =encode_base64(data.as_bytes());// Base64 strings are always a multiple of 4 characters long
assert!(encoded.len()%4==0);let decoded =decode_base64(&encoded).expect("Decoding failed");// Make sure the decoded data matches the original data
assert_eq!(decoded, data.as_bytes());}}