# ========================================================================= # CMock - Automatic Mock Generation for C # ThrowTheSwitch.org # Copyright (c) 2007-26 Mike Karlesky, Mark VanderVoord, & Greg Williams # SPDX-License-Identifier: MIT # ========================================================================= compiler: path: gcc source_path: 'src/' unit_tests_path: &unit_tests_path 'test/' build_path: &build_path 'build/' options: - -c includes: prefix: '-I' items: - 'src/' - '../../src/' - '../../vendor/unity/src/' - '../../vendor/unity/examples/example_3/helper/' - './build/mocks/' - *unit_tests_path defines: prefix: '-D' items: - __monitor - UNITY_SUPPORT_64 object_files: prefix: '-o' extension: '.o' destination: *build_path linker: path: gcc options: - -lm includes: prefix: '-I' object_files: path: *build_path extension: '.o' bin_files: prefix: '-o' extension: '.exe' destination: *build_path :cmock: # Core conffiguration :plugins: [] # What plugins should be used by CMock? :verbosity: 2 # the options being 0 errors only, 1 warnings and errors, 2 normal info, 3 verbose :when_no_prototypes: :warn # the options being :ignore, :warn, or :erro # File configuration :mock_path: './build/mocks' # Subdirectory to store mocks when generated (default: mocks) :skeleton_path: '' # Subdirectory to store stubs when generated (default: '') :mock_prefix: 'Mock' # Prefix to append to filenames for mocks :mock_suffix: '' # Suffix to append to filenames for mocks # Parser configuration :strippables: ['(?:__attribute__\s*\([ (]*.*?[ )]*\)+)'] :attributes: - __ramfunc - __irq - __fiq - register - extern :c_calling_conventions: - __stdcall - __cdecl - __fastcall :treat_externs: :exclude # the options being :include or :exclud :treat_inlines: :exclude # the options being :include or :exclud # Type handling configuration #:unity_helper_path: '' # specify a string of where to find a unity_helper.h file to discover custom type assertions #:treat_as: {} # optionally add additional types to map custom types #:treat_as_array: {} # hint to cmock that these types are pointers to something #:treat_as_void: [] # hint to cmock that these types are actually aliases of void :memcmp_if_unknown: true # allow cmock to use the memory comparison assertions for unknown types :when_ptr: :compare_data # hint to cmock how to handle pointers in general, the options being :compare_ptr, :compare_data, or :smart # Mock generation configuration :weak: '' # Symbol to use to declare weak functions :enforce_strict_ordering: false # Do we want cmock to enforce ordering of all function calls? :fail_on_unexpected_calls: true # Do we want cmock to fail when it encounters a function call that wasn't expected? :callback_include_count: true # Do we want cmock to include the number of calls to this callback, when using callbacks? :callback_after_arg_check: false # Do we want cmock to enforce an argument check first when using a callback? :includes: # You can add additional includes here, or specify the location with the options below - Types.h #:includes_h_pre_orig_header: [] #:includes_h_post_orig_header: [] #:includes_c_pre_header: [] #:includes_c_post_header: [] #:array_size_type: [] # Specify a type or types that should be used for array lengths #:array_size_name: 'size|len' # Specify a name or names that CMock might automatically recognize as the length of an array :exclude_setjmp_h: false # Don't use setjmp when running CMock. Note that this might result in late reporting or out-of-order failures. colour: true