1 #ifndef CPER_IR_TEST_UTILS_H 2 #define CPER_IR_TEST_UTILS_H 3 4 #ifdef __cplusplus 5 extern "C" { 6 #endif 7 8 #include <stdio.h> 9 #include <libcper/BaseTypes.h> 10 #include <libcper/generator/sections/gen-section.h> 11 #include <json.h> 12 13 // Controls whether required properties are added to the majority of property 14 // definitions. This is useful for unit tests that are validating JSON where 15 // all fields are valid 16 enum AddRequiredProps { AddRequired, NoModify }; 17 18 FILE *generate_record_memstream(const char **types, UINT16 num_types, 19 char **buf, size_t *buf_size, 20 int single_section, 21 GEN_VALID_BITS_TEST_TYPE validBitsType); 22 23 int schema_validate_from_file(json_object *to_test, int single_section, 24 int all_valid_bits); 25 26 #ifdef __cplusplus 27 } 28 #endif 29 30 #endif 31