Open parmi93 opened 6 months ago
I temporarily solved the problem by adding this parameter in the project.yml
file, but I think it is not the correct way to disable this functionality as array_size_name
should be a regular expression.
:cmock:
:array_size_name: 'disable'
read_interface.h:
read.h
read.c
test_read.c
mock_read_interface.c
Ceedling Output:
The problem seems to be the
CMockExpectParameters_read_interface(cmock_call_instance, bytes_to_read, buff_size, buff_size, buffer, 1);
call where the argumentbuff_size
is passed asbytes_to_read_Depth
parameter instead of just1
, the right call should beCMockExpectParameters_read_interface(cmock_call_instance, bytes_to_read, 1, buff_size, buffer, 1);
I noticed that if I change the name of the
buff_size
parameter infoo
the problem is solved, it seems that this problem occurs only when in the name of the parameter there is the sub-stringsize
orlength
, so this worksvoid read_interface(size_t *bytes_to_read, size_t foo, char **buffer);
I'm not sure but I think this behavior is due because of this functionality: https://github.com/ThrowTheSwitch/CMock/issues/189
How can I solve the problem without having to change the name of the parameter?