Github User Fetcher 1.0.0
C Application with Server and GUI
Loading...
Searching...
No Matches
Array assertions

Macros

#define cr_assert_arr_eq(Actual, Expected, Size, FormatString, ...)   internal
 
#define cr_expect_arr_eq(Actual, Expected, Size, FormatString, ...)   internal
 
#define cr_assert_arr_neq(Actual, Unexpected, Size, FormatString, ...)   internal
 
#define cr_expect_arr_neq(Actual, Unexpected, Size, FormatString, ...)   internal
 

Detailed Description

Macro Definition Documentation

◆ cr_assert_arr_eq

#define cr_assert_arr_eq ( Actual,
Expected,
Size,
FormatString,
... )   internal

Passes if Actual is byte-to-byte equal to Expected

Passes if Actual is byte-to-byte equal to Expected. Otherwise the test is marked as failure and the execution of the function is aborted.

The optional string is printed on failure.

Warning
This should not be used on struct arrays, consider using cr_assert_arr_eq_cmp() instead.
Parameters
[in]ActualArray to test
[in]ExpectedExpected array
[in]SizeNumber of bytes to check
[in]FormatString(optional) printf-like format string
[in]...(optional) format string parameters

Definition at line 1109 of file assert.h.

◆ cr_assert_arr_neq

#define cr_assert_arr_neq ( Actual,
Unexpected,
Size,
FormatString,
... )   internal

Passes if Actual is not byte-to-byte equal to Expected

Passes if Actual is not byte-to-byte equal to Unexpected. Otherwise the test is marked as failure and the execution of the function is aborted.

The optional string is printed on failure.

Warning
This should not be used on struct arrays, consider using cr_assert_arr_neq_cmp() instead.
Parameters
[in]ActualArray to test
[in]UnexpectedUnexpected array
[in]SizeNumber of bytes to check
[in]FormatString(optional) printf-like format string
[in]...(optional) format string parameters

Definition at line 1150 of file assert.h.

◆ cr_expect_arr_eq

#define cr_expect_arr_eq ( Actual,
Expected,
Size,
FormatString,
... )   internal

Passes if Actual is byte-to-byte equal to Expected

Passes if Actual is byte-to-byte equal to Expected. Otherwise the test is marked as failure but the execution will continue.

The optional string is printed on failure.

Warning
This should not be used on struct arrays, consider using cr_expect_arr_eq_cmp() instead.
Parameters
[in]ActualArray to test
[in]ExpectedExpected array
[in]SizeNumber of bytes to check
[in]FormatString(optional) printf-like format string
[in]...(optional) format string parameters

Definition at line 1129 of file assert.h.

◆ cr_expect_arr_neq

#define cr_expect_arr_neq ( Actual,
Unexpected,
Size,
FormatString,
... )   internal

Passes if Actual is not byte-to-byte equal to Unexpected

Passes if Actual is not byte-to-byte equal to Expected. Otherwise the test is marked as failure but the execution will continue.

The optional string is printed on failure.

Warning
This should not be used on struct arrays, consider using cr_expect_arr_neq_cmp() instead.
Parameters
[in]ActualArray to test
[in]UnexpectedUnexpected array
[in]SizeNumber of bytes to check
[in]FormatString(optional) printf-like format string
[in]...(optional) format string parameters

Definition at line 1170 of file assert.h.