class TestBlobData
Defined at line 66 of file ../../src/storage/blobfs/test/blob_utils.h
Class for creating blob data and generating its merkle root.
Public Methods
template <integral T>
TestBlobData CreatePrefixed (size_t size, T prefix)
Generates a blob starting with the bytes from |prefix|. The remainder of the blob is filled
with 0xAB. |size| must be at least as large as sizeof(prefix).
Defined at line 76 of file ../../src/storage/blobfs/test/blob_utils.h
std::span<const uint8_t> data ()
Defined at line 92 of file ../../src/storage/blobfs/test/blob_utils.h
const Digest & digest ()
Defined at line 93 of file ../../src/storage/blobfs/test/blob_utils.h
void TestBlobData (TestBlobData && )
Defined at line 95 of file ../../src/storage/blobfs/test/blob_utils.h
TestBlobData & operator= (TestBlobData && )
Defined at line 96 of file ../../src/storage/blobfs/test/blob_utils.h
void TestBlobData (fbl::Array<uint8_t> data)
Defined at line 146 of file ../../src/storage/blobfs/test/blob_utils.cc
TestBlobData Create (size_t size, uint8_t fill)
Generates a blob containing `fill` repeatedly.
Defined at line 149 of file ../../src/storage/blobfs/test/blob_utils.cc
TestBlobData CreateRealistic (size_t size, int prefix)
Generates a blob with realistic data (derived from, for example, an ELF binary). `prefix` is
placed at the start of the blob which allows for the same realistic data to be used to create
multiple distinct blobs.
Defined at line 158 of file ../../src/storage/blobfs/test/blob_utils.cc
TestBlobData CreateRandom (size_t size)
Generates a blob with bytes generated from `rand`.
Defined at line 181 of file ../../src/storage/blobfs/test/blob_utils.cc