This class configures mock objects with reasonable defaults. More...
#include <sw/device/silicon_creator/lib/bootstrap_fuzzer_util.h>
Public Member Functions | |
AbstractBootstrapMockGroup (StreamParser stream, bool verbose) | |
AbstractBootstrapMockGroup (AbstractBootstrapMockGroup &)=delete | |
AbstractBootstrapMockGroup (AbstractBootstrapMockGroup &&)=delete | |
virtual void | ConfigureMocks () |
This method configures the mocks owned by AbstractBootstrapMockGroup . More... | |
Protected Attributes | |
bool | verbose_ {false} |
bool | flash_status_override_ {false} |
size_t | max_spi_cmd_count_ {0} |
size_t | spi_cmd_count_ {0} |
StreamParser | stream_ |
::rom_test::NiceMockSpiDevice | spi_device_ |
::rom_test::NiceMockRstmgr | rstmgr_ |
::rom_test::NiceMockFlashCtrl | flash_ctrl_ |
::rom_test::NiceMockOtp | otp_ |
This class configures mock objects with reasonable defaults.
Some mocks will enable the fuzzing engine to drive control flow by getting values from a StreamParser
. Instantiate this class once per call to LLVMFuzzerTestOneInput()
.
Definition at line 124 of file bootstrap_fuzzer_util.h.
bootstrap_fuzzer::AbstractBootstrapMockGroup::AbstractBootstrapMockGroup | ( | StreamParser | stream, |
bool | verbose | ||
) |
data | A chunk of data generated by the fuzzing engine. |
verbose | Whether to enable verbose logging. |
Definition at line 38 of file bootstrap_fuzzer_util.cc.
|
virtual |
This method configures the mocks owned by AbstractBootstrapMockGroup
.
If you add custom mocks in a derived class and override this method, be sure to call AbstractBootstrapMockGroup::ConfigureMocks()
.
Reimplemented in anonymous_namespace{bootstrap_fuzz_test.cc}::RomMockGroup.
Definition at line 42 of file bootstrap_fuzzer_util.cc.