Skip to content

Commit c6f8e4a

Browse files
authored
Merge pull request cpputest#40 from youduda/C-Interface_add-assertions
Add _TEXT and missing assertions to C-Interface list
2 parents 6a3ecca + 90063e4 commit c6f8e4a

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

manual.markdown

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -531,17 +531,29 @@ You can leave out TEST_GROUP_C_SETUP() / TEST_GROUP_C_TEARDOWN() and TEST_GROUP_
531531
The following assertion macros are supported in the pure C interface:
532532

533533
{% highlight c++ %}
534+
CHECK_EQUAL_C_BOOL(expected,actual);
534535
CHECK_EQUAL_C_INT(expected,actual);
536+
CHECK_EQUAL_C_UINT(expected,actual);
537+
CHECK_EQUAL_C_LONG(expected,actual);
538+
CHECK_EQUAL_C_ULONG(expected,actual);
539+
CHECK_EQUAL_C_LONGLONG(expected,actual);
540+
CHECK_EQUAL_C_ULONGLONG(expected,actual);
535541
CHECK_EQUAL_C_REAL(expected,actual,threshold);
536542
CHECK_EQUAL_C_CHAR(expected,actual);
543+
CHECK_EQUAL_C_UBYTE(expected,actual);
544+
CHECK_EQUAL_C_SBYTE(expected,actual);
537545
CHECK_EQUAL_C_STRING(expected,actual);
538546
CHECK_EQUAL_C_POINTER(expected,actual); /* v3.8 */
539547
CHECK_EQUAL_C_BITS(expected, actual, mask); /* v3.8, pending */
540548
FAIL_TEXT_C(text);
541549
FAIL_C();
542550
CHECK_C(condition);
551+
CHECK_C_TEXT(condition, text);
543552
{% endhighlight %}
544553

554+
*NOTE* LONGLONG assertions are disabled by default.
555+
*NOTE2* All macros have _TEXT() equivalents like CHECK_C_TEXT(), which are not explicitly listed here.
556+
545557
These macros ensure tests get terminated in a way appropriate for pure C code.
546558

547559
<a id="gmock"> </a>

0 commit comments

Comments
 (0)