Debian Codegraph @

third_party/rust/mls-rs-provider-sqlite/src/test_utils.rs

raw
1 // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2 // Copyright by contributors to this project.
3 // SPDX-License-Identifier: (Apache-2.0 OR MIT)
4
5 use rand::RngCore;
6 pub fn gen_rand_bytes(size: usize) -> Vec<u8> {
7 let mut bytes: Vec<u8> = vec![0; size];
8 rand::thread_rng().fill_bytes(&mut bytes);
9 bytes
10 }