CryptoAuthLib
Atmel CryptoAuthentication Library
unity_internals.h
Go to the documentation of this file.
1 /* ==========================================
2  Unity Project - A Test Framework for C
3  Copyright (c) 2007-14 Mike Karlesky, Mark VanderVoord, Greg Williams
4  [Released under MIT License. Please refer to license.txt for details]
5  ========================================== */
6 
7 #ifndef UNITY_INTERNALS_H
8 #define UNITY_INTERNALS_H
9 
10 #ifdef UNITY_INCLUDE_CONFIG_H
11 #include "unity_config.h"
12 #endif
13 
14 #include <setjmp.h>
15 
16 // Unity Attempts to Auto-Detect Integer Types
17 // Attempt 1: UINT_MAX, ULONG_MAX, etc in <stdint.h>
18 // Attempt 2: UINT_MAX, ULONG_MAX, etc in <limits.h>
19 // Attempt 3: Deduced from sizeof() macros
20 #ifndef UNITY_EXCLUDE_STDINT_H
21 #include <stdint.h>
22 #endif
23 
24 #ifndef UNITY_EXCLUDE_LIMITS_H
25 #include <limits.h>
26 #endif
27 
28 #ifndef UNITY_EXCLUDE_SIZEOF
29 #ifndef UINT_MAX
30 #define UINT_MAX (sizeof(unsigned int) * 256 - 1)
31 #endif
32 #ifndef ULONG_MAX
33 #define ULONG_MAX (sizeof(unsigned long) * 256 - 1)
34 #endif
35 #ifndef UINTPTR_MAX
36 //apparently this is not a constant expression: (sizeof(unsigned int *) * 256 - 1) so we have to just let this fall through
37 #endif
38 #endif
39 //-------------------------------------------------------
40 // Guess Widths If Not Specified
41 //-------------------------------------------------------
42 
43 // Determine the size of an int, if not already specificied.
44 // We cannot use sizeof(int), because it is not yet defined
45 // at this stage in the trnslation of the C program.
46 // Therefore, infer it from UINT_MAX if possible.
47 #ifndef UNITY_INT_WIDTH
48  #ifdef UINT_MAX
49  #if (UINT_MAX == 0xFFFF)
50  #define UNITY_INT_WIDTH (16)
51  #elif (UINT_MAX == 0xFFFFFFFF)
52  #define UNITY_INT_WIDTH (32)
53  #elif (UINT_MAX == 0xFFFFFFFFFFFFFFFF)
54  #define UNITY_INT_WIDTH (64)
55  #endif
56  #endif
57 #endif
58 #ifndef UNITY_INT_WIDTH
59  #define UNITY_INT_WIDTH (32)
60 #endif
61 
62 // Determine the size of a long, if not already specified,
63 // by following the process used above to define
64 // UNITY_INT_WIDTH.
65 #ifndef UNITY_LONG_WIDTH
66  #ifdef ULONG_MAX
67  #if (ULONG_MAX == 0xFFFF)
68  #define UNITY_LONG_WIDTH (16)
69  #elif (ULONG_MAX == 0xFFFFFFFF)
70  #define UNITY_LONG_WIDTH (32)
71  #elif (ULONG_MAX == 0xFFFFFFFFFFFFFFFF)
72  #define UNITY_LONG_WIDTH (64)
73  #endif
74  #endif
75 #endif
76 #ifndef UNITY_LONG_WIDTH
77  #define UNITY_LONG_WIDTH (32)
78 #endif
79 
80 // Determine the size of a pointer, if not already specified,
81 // by following the process used above to define
82 // UNITY_INT_WIDTH.
83 #ifndef UNITY_POINTER_WIDTH
84  #ifdef UINTPTR_MAX
85  #if (UINTPTR_MAX <= 0xFFFF)
86  #define UNITY_POINTER_WIDTH (16)
87  #elif (UINTPTR_MAX <= 0xFFFFFFFF)
88  #define UNITY_POINTER_WIDTH (32)
89  #elif (UINTPTR_MAX <= 0xFFFFFFFFFFFFFFFF)
90  #define UNITY_POINTER_WIDTH (64)
91  #endif
92  #endif
93 #endif
94 #ifndef UNITY_POINTER_WIDTH
95  #ifdef INTPTR_MAX
96  #if (INTPTR_MAX <= 0x7FFF)
97  #define UNITY_POINTER_WIDTH (16)
98  #elif (INTPTR_MAX <= 0x7FFFFFFF)
99  #define UNITY_POINTER_WIDTH (32)
100  #elif (INTPTR_MAX <= 0x7FFFFFFFFFFFFFFF)
101  #define UNITY_POINTER_WIDTH (64)
102  #endif
103  #endif
104 #endif
105 #ifndef UNITY_POINTER_WIDTH
106  #define UNITY_POINTER_WIDTH UNITY_LONG_WIDTH
107 #endif
108 
109 //-------------------------------------------------------
110 // Int Support (Define types based on detected sizes)
111 //-------------------------------------------------------
112 
113 #if (UNITY_INT_WIDTH == 32)
114 typedef unsigned char _UU8;
115 typedef unsigned short _UU16;
116 typedef unsigned int _UU32;
117 typedef signed char _US8;
118 typedef signed short _US16;
119 typedef signed int _US32;
120 #elif (UNITY_INT_WIDTH == 16)
121 typedef unsigned char _UU8;
122 typedef unsigned int _UU16;
123 typedef unsigned long _UU32;
124 typedef signed char _US8;
125 typedef signed int _US16;
126 typedef signed long _US32;
127 #else
128  #error Invalid UNITY_INT_WIDTH specified! (16 or 32 are supported)
129 #endif
130 
131 //-------------------------------------------------------
132 // 64-bit Support
133 //-------------------------------------------------------
134 
135 #ifndef UNITY_SUPPORT_64
136 #if UNITY_LONG_WIDTH > 32
137 #define UNITY_SUPPORT_64
138 #endif
139 #endif
140 #ifndef UNITY_SUPPORT_64
141 #if UNITY_POINTER_WIDTH > 32
142 #define UNITY_SUPPORT_64
143 #endif
144 #endif
145 
146 #ifndef UNITY_SUPPORT_64
147 
148 //No 64-bit Support
149 typedef _UU32 _U_UINT;
150 typedef _US32 _U_SINT;
151 
152 #else
153 
154 //64-bit Support
155 #if (UNITY_LONG_WIDTH == 32)
156 typedef unsigned long long _UU64;
157 typedef signed long long _US64;
158 #elif (UNITY_LONG_WIDTH == 64)
159 typedef unsigned long _UU64;
160 typedef signed long _US64;
161 #else
162  #error Invalid UNITY_LONG_WIDTH specified! (32 or 64 are supported)
163 #endif
164 typedef _UU64 _U_UINT;
165 typedef _US64 _U_SINT;
166 
167 #endif
168 
169 //-------------------------------------------------------
170 // Pointer Support
171 //-------------------------------------------------------
172 
173 #if (UNITY_POINTER_WIDTH == 32)
174 typedef _UU32 _UP;
175 #define UNITY_DISPLAY_STYLE_POINTER UNITY_DISPLAY_STYLE_HEX32
176 #elif (UNITY_POINTER_WIDTH == 64)
177 typedef _UU64 _UP;
178 #define UNITY_DISPLAY_STYLE_POINTER UNITY_DISPLAY_STYLE_HEX64
179 #elif (UNITY_POINTER_WIDTH == 16)
180 typedef _UU16 _UP;
181 #define UNITY_DISPLAY_STYLE_POINTER UNITY_DISPLAY_STYLE_HEX16
182 #else
183  #error Invalid UNITY_POINTER_WIDTH specified! (16, 32 or 64 are supported)
184 #endif
185 
186 #ifndef UNITY_PTR_ATTRIBUTE
187  #define UNITY_PTR_ATTRIBUTE
188 #endif
189 
190 //-------------------------------------------------------
191 // Float Support
192 //-------------------------------------------------------
193 
194 #ifdef UNITY_EXCLUDE_FLOAT
195 
196 //No Floating Point Support
197 #undef UNITY_INCLUDE_FLOAT
198 #undef UNITY_FLOAT_PRECISION
199 #undef UNITY_FLOAT_TYPE
200 #undef UNITY_FLOAT_VERBOSE
201 
202 #else
203 
204 #ifndef UNITY_INCLUDE_FLOAT
205 #define UNITY_INCLUDE_FLOAT
206 #endif
207 
208 //Floating Point Support
209 #ifndef UNITY_FLOAT_PRECISION
210 #define UNITY_FLOAT_PRECISION (0.00001f)
211 #endif
212 #ifndef UNITY_FLOAT_TYPE
213 #define UNITY_FLOAT_TYPE float
214 #endif
216 
217 #endif
218 
219 //-------------------------------------------------------
220 // Double Float Support
221 //-------------------------------------------------------
222 
223 //unlike FLOAT, we DON'T include by default
224 #ifndef UNITY_EXCLUDE_DOUBLE
225 #ifndef UNITY_INCLUDE_DOUBLE
226 #define UNITY_EXCLUDE_DOUBLE
227 #endif
228 #endif
229 
230 #ifdef UNITY_EXCLUDE_DOUBLE
231 
232 //No Floating Point Support
233 #undef UNITY_DOUBLE_PRECISION
234 #undef UNITY_DOUBLE_TYPE
235 #undef UNITY_DOUBLE_VERBOSE
236 
237 #ifdef UNITY_INCLUDE_DOUBLE
238 #undef UNITY_INCLUDE_DOUBLE
239 #endif
240 
241 #else
242 
243 //Double Floating Point Support
244 #ifndef UNITY_DOUBLE_PRECISION
245 #define UNITY_DOUBLE_PRECISION (1e-12f)
246 #endif
247 #ifndef UNITY_DOUBLE_TYPE
248 #define UNITY_DOUBLE_TYPE double
249 #endif
250 typedef UNITY_DOUBLE_TYPE _UD;
251 
252 #endif
253 
254 #ifdef UNITY_DOUBLE_VERBOSE
255 #ifndef UNITY_FLOAT_VERBOSE
256 #define UNITY_FLOAT_VERBOSE
257 #endif
258 #endif
259 
260 //-------------------------------------------------------
261 // Output Method: stdout (DEFAULT)
262 //-------------------------------------------------------
263 #ifndef UNITY_OUTPUT_CHAR
264 //Default to using putchar, which is defined in stdio.h
265 #include <stdio.h>
266 #define UNITY_OUTPUT_CHAR(a) putchar(a)
267 #else
268 //If defined as something else, make sure we declare it here so it's ready for use
269 extern int UNITY_OUTPUT_CHAR(int);
270 #endif
271 
272 #ifndef UNITY_OUTPUT_START
273 #define UNITY_OUTPUT_START()
274 #endif
275 
276 #ifndef UNITY_OUTPUT_COMPLETE
277 #define UNITY_OUTPUT_COMPLETE()
278 #endif
279 
280 //-------------------------------------------------------
281 // Footprint
282 //-------------------------------------------------------
283 
284 #ifndef UNITY_LINE_TYPE
285 #define UNITY_LINE_TYPE _U_UINT
286 #endif
287 
288 #ifndef UNITY_COUNTER_TYPE
289 #define UNITY_COUNTER_TYPE _U_UINT
290 #endif
291 
292 //-------------------------------------------------------
293 // Language Features Available
294 //-------------------------------------------------------
295 #if !defined(UNITY_WEAK_ATTRIBUTE) && !defined(UNITY_WEAK_PRAGMA)
296 # ifdef __GNUC__ // includes clang
297 # if !(defined(__WIN32__) && defined(__clang__))
298 # define UNITY_WEAK_ATTRIBUTE __attribute__((weak))
299 # endif
300 # endif
301 #endif
302 
303 #ifdef UNITY_NO_WEAK
304 # undef UNITY_WEAK_ATTRIBUTE
305 # undef UNITY_WEAK_PRAGMA
306 #endif
307 
308 
309 //-------------------------------------------------------
310 // Internal Structs Needed
311 //-------------------------------------------------------
312 
313 typedef void (*UnityTestFunction)(void);
314 
315 #define UNITY_DISPLAY_RANGE_INT (0x10)
316 #define UNITY_DISPLAY_RANGE_UINT (0x20)
317 #define UNITY_DISPLAY_RANGE_HEX (0x40)
318 #define UNITY_DISPLAY_RANGE_AUTO (0x80)
319 
320 typedef enum {
321 #if (UNITY_INT_WIDTH == 16)
323 #elif (UNITY_INT_WIDTH == 32)
325 #elif (UNITY_INT_WIDTH == 64)
327 #endif
331 #ifdef UNITY_SUPPORT_64
332  UNITY_DISPLAY_STYLE_INT64 = 8 + UNITY_DISPLAY_RANGE_INT,
333 #endif
334 
335 #if (UNITY_INT_WIDTH == 16)
337 #elif (UNITY_INT_WIDTH == 32)
338  UNITY_DISPLAY_STYLE_UINT = 4 + UNITY_DISPLAY_RANGE_UINT + UNITY_DISPLAY_RANGE_AUTO,
339 #elif (UNITY_INT_WIDTH == 64)
340  UNITY_DISPLAY_STYLE_UINT = 8 + UNITY_DISPLAY_RANGE_UINT + UNITY_DISPLAY_RANGE_AUTO,
341 #endif
345 #ifdef UNITY_SUPPORT_64
346  UNITY_DISPLAY_STYLE_UINT64 = 8 + UNITY_DISPLAY_RANGE_UINT,
347 #endif
351 #ifdef UNITY_SUPPORT_64
352  UNITY_DISPLAY_STYLE_HEX64 = 8 + UNITY_DISPLAY_RANGE_HEX,
353 #endif
356 
357 #ifndef UNITY_EXCLUDE_FLOAT
358 typedef enum _UNITY_FLOAT_TRAIT_T {
368 #endif
369 
370 struct _Unity {
371  const char* TestFile;
372  const char* CurrentTestName;
379  jmp_buf AbortFrame;
380 };
381 
382 extern struct _Unity Unity;
383 
384 //-------------------------------------------------------
385 // Test Suite Management
386 //-------------------------------------------------------
387 
388 void UnityBegin(const char* filename);
389 int UnityEnd(void);
390 void UnityConcludeTest(void);
391 void UnityDefaultTestRun(UnityTestFunction Func, const char* FuncName, const int FuncLineNum);
392 
393 //-------------------------------------------------------
394 // Test Output
395 //-------------------------------------------------------
396 
397 void UnityPrint(const char* string);
398 void UnityPrintMask(const _U_UINT mask, const _U_UINT number);
399 void UnityPrintNumberByStyle(const _U_SINT number, const UNITY_DISPLAY_STYLE_T style);
400 void UnityPrintNumber(const _U_SINT number);
401 void UnityPrintNumberUnsigned(const _U_UINT number);
402 void UnityPrintNumberHex(const _U_UINT number, const char nibbles);
403 
404 #ifdef UNITY_FLOAT_VERBOSE
405 void UnityPrintFloat(const _UF number);
406 #endif
407 
408 //-------------------------------------------------------
409 // Test Assertion Fuctions
410 //-------------------------------------------------------
411 // Use the macros below this section instead of calling
412 // these directly. The macros have a consistent naming
413 // convention and will pull in file and line information
414 // for you.
415 
416 void UnityAssertEqualNumber(const _U_SINT expected,
417  const _U_SINT actual,
418  const char* msg,
419  const UNITY_LINE_TYPE lineNumber,
420  const UNITY_DISPLAY_STYLE_T style);
421 
422 void UnityAssertEqualIntArray(UNITY_PTR_ATTRIBUTE const void* expected,
423  UNITY_PTR_ATTRIBUTE const void* actual,
424  const _UU32 num_elements,
425  const char* msg,
426  const UNITY_LINE_TYPE lineNumber,
427  const UNITY_DISPLAY_STYLE_T style);
428 
429 void UnityAssertBits(const _U_SINT mask,
430  const _U_SINT expected,
431  const _U_SINT actual,
432  const char* msg,
433  const UNITY_LINE_TYPE lineNumber);
434 
435 void UnityAssertEqualString(const char* expected,
436  const char* actual,
437  const char* msg,
438  const UNITY_LINE_TYPE lineNumber);
439 
440 void UnityAssertEqualStringArray( const char** expected,
441  const char** actual,
442  const _UU32 num_elements,
443  const char* msg,
444  const UNITY_LINE_TYPE lineNumber);
445 
446 void UnityAssertEqualMemory( UNITY_PTR_ATTRIBUTE const void* expected,
447  UNITY_PTR_ATTRIBUTE const void* actual,
448  const _UU32 length,
449  const _UU32 num_elements,
450  const char* msg,
451  const UNITY_LINE_TYPE lineNumber);
452 
453 void UnityAssertNumbersWithin(const _U_SINT delta,
454  const _U_SINT expected,
455  const _U_SINT actual,
456  const char* msg,
457  const UNITY_LINE_TYPE lineNumber,
458  const UNITY_DISPLAY_STYLE_T style);
459 
460 void UnityFail(const char* message, const UNITY_LINE_TYPE line);
461 
462 void UnityIgnore(const char* message, const UNITY_LINE_TYPE line);
463 
464 #ifndef UNITY_EXCLUDE_FLOAT
465 void UnityAssertFloatsWithin(const _UF delta,
466  const _UF expected,
467  const _UF actual,
468  const char* msg,
469  const UNITY_LINE_TYPE lineNumber);
470 
472  UNITY_PTR_ATTRIBUTE const _UF* actual,
473  const _UU32 num_elements,
474  const char* msg,
475  const UNITY_LINE_TYPE lineNumber);
476 
477 void UnityAssertFloatSpecial(const _UF actual,
478  const char* msg,
479  const UNITY_LINE_TYPE lineNumber,
480  const UNITY_FLOAT_TRAIT_T style);
481 #endif
482 
483 #ifndef UNITY_EXCLUDE_DOUBLE
484 void UnityAssertDoublesWithin(const _UD delta,
485  const _UD expected,
486  const _UD actual,
487  const char* msg,
488  const UNITY_LINE_TYPE lineNumber);
489 
490 void UnityAssertEqualDoubleArray(UNITY_PTR_ATTRIBUTE const _UD* expected,
491  UNITY_PTR_ATTRIBUTE const _UD* actual,
492  const _UU32 num_elements,
493  const char* msg,
494  const UNITY_LINE_TYPE lineNumber);
495 
496 void UnityAssertDoubleSpecial(const _UD actual,
497  const char* msg,
498  const UNITY_LINE_TYPE lineNumber,
499  const UNITY_FLOAT_TRAIT_T style);
500 #endif
501 
502 //-------------------------------------------------------
503 // Error Strings We Might Need
504 //-------------------------------------------------------
505 
506 extern const char UnityStrErrFloat[];
507 extern const char UnityStrErrDouble[];
508 extern const char UnityStrErr64[];
509 
510 //-------------------------------------------------------
511 // Test Running Macros
512 //-------------------------------------------------------
513 
514 #define TEST_PROTECT() (setjmp(Unity.AbortFrame) == 0)
515 
516 #define TEST_ABORT() { longjmp(Unity.AbortFrame, 1); }
517 
518 //This tricky series of macros gives us an optional line argument to treat it as RUN_TEST(func, num=__LINE__)
519 #ifndef RUN_TEST
520 #ifdef __STDC_VERSION__
521 #if __STDC_VERSION__ >= 199901L
522 #define RUN_TEST(...) UnityDefaultTestRun(RUN_TEST_FIRST(__VA_ARGS__), RUN_TEST_SECOND(__VA_ARGS__))
523 #define RUN_TEST_FIRST(...) RUN_TEST_FIRST_HELPER(__VA_ARGS__, throwaway)
524 #define RUN_TEST_FIRST_HELPER(first, ...) first, #first
525 #define RUN_TEST_SECOND(...) RUN_TEST_SECOND_HELPER(__VA_ARGS__, __LINE__, throwaway)
526 #define RUN_TEST_SECOND_HELPER(first, second, ...) second
527 #endif
528 #endif
529 #endif
530 
531 //If we can't do the tricky version, we'll just have to require them to always include the line number
532 #ifndef RUN_TEST
533 #ifdef CMOCK
534 #define RUN_TEST(func, num) UnityDefaultTestRun(func, #func, num)
535 #else
536 #define RUN_TEST(func) UnityDefaultTestRun(func, #func, __LINE__)
537 #endif
538 #endif
539 
540 #define TEST_LINE_NUM (Unity.CurrentTestLineNumber)
541 #define TEST_IS_IGNORED (Unity.CurrentTestIgnored)
542 #define UNITY_NEW_TEST(a) \
543  Unity.CurrentTestName = a; \
544  Unity.CurrentTestLineNumber = (UNITY_LINE_TYPE)(__LINE__); \
545  Unity.NumberOfTests++;
546 
547 #ifndef UNITY_BEGIN
548 #define UNITY_BEGIN() UnityBegin(__FILE__)
549 #endif
550 
551 #ifndef UNITY_END
552 #define UNITY_END() UnityEnd()
553 #endif
554 
555 //-------------------------------------------------------
556 // Basic Fail and Ignore
557 //-------------------------------------------------------
558 
559 #define UNITY_TEST_FAIL(line, message) UnityFail( (message), (UNITY_LINE_TYPE)line);
560 #define UNITY_TEST_IGNORE(line, message) UnityIgnore( (message), (UNITY_LINE_TYPE)line);
561 
562 //-------------------------------------------------------
563 // Test Asserts
564 //-------------------------------------------------------
565 
566 #define UNITY_TEST_ASSERT(condition, line, message) if (condition) {} else { UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, message); }
567 #define UNITY_TEST_ASSERT_NULL(pointer, line, message) UNITY_TEST_ASSERT(((pointer) == NULL), (UNITY_LINE_TYPE)line, message)
568 #define UNITY_TEST_ASSERT_NOT_NULL(pointer, line, message) UNITY_TEST_ASSERT(((pointer) != NULL), (UNITY_LINE_TYPE)line, message)
569 
570 #define UNITY_TEST_ASSERT_EQUAL_INT(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT)
571 #define UNITY_TEST_ASSERT_EQUAL_INT8(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US8 )(expected), (_U_SINT)(_US8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT8)
572 #define UNITY_TEST_ASSERT_EQUAL_INT16(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US16)(expected), (_U_SINT)(_US16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT16)
573 #define UNITY_TEST_ASSERT_EQUAL_INT32(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US32)(expected), (_U_SINT)(_US32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT32)
574 #define UNITY_TEST_ASSERT_EQUAL_UINT(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT)
575 #define UNITY_TEST_ASSERT_EQUAL_UINT8(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_UU8 )(expected), (_U_SINT)(_UU8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT8)
576 #define UNITY_TEST_ASSERT_EQUAL_UINT16(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_UU16)(expected), (_U_SINT)(_UU16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT16)
577 #define UNITY_TEST_ASSERT_EQUAL_UINT32(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_UU32)(expected), (_U_SINT)(_UU32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT32)
578 #define UNITY_TEST_ASSERT_EQUAL_HEX8(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US8 )(expected), (_U_SINT)(_US8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX8)
579 #define UNITY_TEST_ASSERT_EQUAL_HEX16(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US16)(expected), (_U_SINT)(_US16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX16)
580 #define UNITY_TEST_ASSERT_EQUAL_HEX32(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_US32)(expected), (_U_SINT)(_US32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX32)
581 #define UNITY_TEST_ASSERT_BITS(mask, expected, actual, line, message) UnityAssertBits((_U_SINT)(mask), (_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line)
582 
583 #define UNITY_TEST_ASSERT_INT_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(delta), (_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT)
584 #define UNITY_TEST_ASSERT_INT8_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_US8 )(delta), (_U_SINT)(_US8 )(expected), (_U_SINT)(_US8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT8)
585 #define UNITY_TEST_ASSERT_INT16_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_US16)(delta), (_U_SINT)(_US16)(expected), (_U_SINT)(_US16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT16)
586 #define UNITY_TEST_ASSERT_INT32_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_US32)(delta), (_U_SINT)(_US32)(expected), (_U_SINT)(_US32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT32)
587 #define UNITY_TEST_ASSERT_UINT_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(delta), (_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT)
588 #define UNITY_TEST_ASSERT_UINT8_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU8 )(delta), (_U_SINT)(_U_UINT)(_UU8 )(expected), (_U_SINT)(_U_UINT)(_UU8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT8)
589 #define UNITY_TEST_ASSERT_UINT16_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU16)(delta), (_U_SINT)(_U_UINT)(_UU16)(expected), (_U_SINT)(_U_UINT)(_UU16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT16)
590 #define UNITY_TEST_ASSERT_UINT32_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU32)(delta), (_U_SINT)(_U_UINT)(_UU32)(expected), (_U_SINT)(_U_UINT)(_UU32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT32)
591 #define UNITY_TEST_ASSERT_HEX8_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU8 )(delta), (_U_SINT)(_U_UINT)(_UU8 )(expected), (_U_SINT)(_U_UINT)(_UU8 )(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX8)
592 #define UNITY_TEST_ASSERT_HEX16_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU16)(delta), (_U_SINT)(_U_UINT)(_UU16)(expected), (_U_SINT)(_U_UINT)(_UU16)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX16)
593 #define UNITY_TEST_ASSERT_HEX32_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(_U_UINT)(_UU32)(delta), (_U_SINT)(_U_UINT)(_UU32)(expected), (_U_SINT)(_U_UINT)(_UU32)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX32)
594 
595 #define UNITY_TEST_ASSERT_EQUAL_PTR(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(_UP)(expected), (_U_SINT)(_UP)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_POINTER)
596 #define UNITY_TEST_ASSERT_EQUAL_STRING(expected, actual, line, message) UnityAssertEqualString((const char*)(expected), (const char*)(actual), (message), (UNITY_LINE_TYPE)line)
597 #define UNITY_TEST_ASSERT_EQUAL_MEMORY(expected, actual, len, line, message) UnityAssertEqualMemory((UNITY_PTR_ATTRIBUTE void*)(expected), (UNITY_PTR_ATTRIBUTE void*)(actual), (_UU32)(len), 1, (message), (UNITY_LINE_TYPE)line)
598 
599 #define UNITY_TEST_ASSERT_EQUAL_INT_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT)
600 #define UNITY_TEST_ASSERT_EQUAL_INT8_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT8)
601 #define UNITY_TEST_ASSERT_EQUAL_INT16_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT16)
602 #define UNITY_TEST_ASSERT_EQUAL_INT32_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT32)
603 #define UNITY_TEST_ASSERT_EQUAL_UINT_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT)
604 #define UNITY_TEST_ASSERT_EQUAL_UINT8_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT8)
605 #define UNITY_TEST_ASSERT_EQUAL_UINT16_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT16)
606 #define UNITY_TEST_ASSERT_EQUAL_UINT32_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT32)
607 #define UNITY_TEST_ASSERT_EQUAL_HEX8_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX8)
608 #define UNITY_TEST_ASSERT_EQUAL_HEX16_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX16)
609 #define UNITY_TEST_ASSERT_EQUAL_HEX32_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(expected), (UNITY_PTR_ATTRIBUTE const void*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX32)
610 #define UNITY_TEST_ASSERT_EQUAL_PTR_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const void*)(_UP*)(expected), (const void*)(_UP*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_POINTER)
611 #define UNITY_TEST_ASSERT_EQUAL_STRING_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualStringArray((const char**)(expected), (const char**)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line)
612 #define UNITY_TEST_ASSERT_EQUAL_MEMORY_ARRAY(expected, actual, len, num_elements, line, message) UnityAssertEqualMemory((UNITY_PTR_ATTRIBUTE void*)(expected), (UNITY_PTR_ATTRIBUTE void*)(actual), (_UU32)(len), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line)
613 
614 #ifdef UNITY_SUPPORT_64
615 #define UNITY_TEST_ASSERT_EQUAL_INT64(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT64)
616 #define UNITY_TEST_ASSERT_EQUAL_UINT64(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT64)
617 #define UNITY_TEST_ASSERT_EQUAL_HEX64(expected, actual, line, message) UnityAssertEqualNumber((_U_SINT)(expected), (_U_SINT)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX64)
618 #define UNITY_TEST_ASSERT_EQUAL_INT64_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const _U_SINT*)(expected), (UNITY_PTR_ATTRIBUTE const _U_SINT*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT64)
619 #define UNITY_TEST_ASSERT_EQUAL_UINT64_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const _U_SINT*)(expected), (UNITY_PTR_ATTRIBUTE const _U_SINT*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT64)
620 #define UNITY_TEST_ASSERT_EQUAL_HEX64_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualIntArray((UNITY_PTR_ATTRIBUTE const _U_SINT*)(expected), (UNITY_PTR_ATTRIBUTE const _U_SINT*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX64)
621 #define UNITY_TEST_ASSERT_INT64_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(delta), (_U_SINT)(expected), (_U_SINT)(actual), NULL, (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_INT64)
622 #define UNITY_TEST_ASSERT_UINT64_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(delta), (_U_SINT)(expected), (_U_SINT)(actual), NULL, (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_UINT64)
623 #define UNITY_TEST_ASSERT_HEX64_WITHIN(delta, expected, actual, line, message) UnityAssertNumbersWithin((_U_SINT)(delta), (_U_SINT)(expected), (_U_SINT)(actual), NULL, (UNITY_LINE_TYPE)line, UNITY_DISPLAY_STYLE_HEX64)
624 #else
625 #define UNITY_TEST_ASSERT_EQUAL_INT64(expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
626 #define UNITY_TEST_ASSERT_EQUAL_UINT64(expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
627 #define UNITY_TEST_ASSERT_EQUAL_HEX64(expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
628 #define UNITY_TEST_ASSERT_EQUAL_INT64_ARRAY(expected, actual, num_elements, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
629 #define UNITY_TEST_ASSERT_EQUAL_UINT64_ARRAY(expected, actual, num_elements, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
630 #define UNITY_TEST_ASSERT_EQUAL_HEX64_ARRAY(expected, actual, num_elements, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
631 #define UNITY_TEST_ASSERT_INT64_WITHIN(delta, expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
632 #define UNITY_TEST_ASSERT_UINT64_WITHIN(delta, expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
633 #define UNITY_TEST_ASSERT_HEX64_WITHIN(delta, expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErr64)
634 #endif
635 
636 #ifdef UNITY_EXCLUDE_FLOAT
637 #define UNITY_TEST_ASSERT_FLOAT_WITHIN(delta, expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
638 #define UNITY_TEST_ASSERT_EQUAL_FLOAT(expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
639 #define UNITY_TEST_ASSERT_EQUAL_FLOAT_ARRAY(expected, actual, num_elements, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
640 #define UNITY_TEST_ASSERT_FLOAT_IS_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
641 #define UNITY_TEST_ASSERT_FLOAT_IS_NEG_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
642 #define UNITY_TEST_ASSERT_FLOAT_IS_NAN(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
643 #define UNITY_TEST_ASSERT_FLOAT_IS_DETERMINATE(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
644 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
645 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_NEG_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
646 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_NAN(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
647 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_DETERMINATE(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrFloat)
648 #else
649 #define UNITY_TEST_ASSERT_FLOAT_WITHIN(delta, expected, actual, line, message) UnityAssertFloatsWithin((_UF)(delta), (_UF)(expected), (_UF)(actual), (message), (UNITY_LINE_TYPE)line)
650 #define UNITY_TEST_ASSERT_EQUAL_FLOAT(expected, actual, line, message) UNITY_TEST_ASSERT_FLOAT_WITHIN((_UF)(expected) * (_UF)UNITY_FLOAT_PRECISION, (_UF)expected, (_UF)actual, (UNITY_LINE_TYPE)line, message)
651 #define UNITY_TEST_ASSERT_EQUAL_FLOAT_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualFloatArray((_UF*)(expected), (_UF*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line)
652 #define UNITY_TEST_ASSERT_FLOAT_IS_INF(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_INF)
653 #define UNITY_TEST_ASSERT_FLOAT_IS_NEG_INF(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NEG_INF)
654 #define UNITY_TEST_ASSERT_FLOAT_IS_NAN(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NAN)
655 #define UNITY_TEST_ASSERT_FLOAT_IS_DETERMINATE(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_DET)
656 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_INF(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_INF)
657 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_NEG_INF(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_NEG_INF)
658 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_NAN(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_NAN)
659 #define UNITY_TEST_ASSERT_FLOAT_IS_NOT_DETERMINATE(actual, line, message) UnityAssertFloatSpecial((_UF)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_DET)
660 #endif
661 
662 #ifdef UNITY_EXCLUDE_DOUBLE
663 #define UNITY_TEST_ASSERT_DOUBLE_WITHIN(delta, expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
664 #define UNITY_TEST_ASSERT_EQUAL_DOUBLE(expected, actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
665 #define UNITY_TEST_ASSERT_EQUAL_DOUBLE_ARRAY(expected, actual, num_elements, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
666 #define UNITY_TEST_ASSERT_DOUBLE_IS_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
667 #define UNITY_TEST_ASSERT_DOUBLE_IS_NEG_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
668 #define UNITY_TEST_ASSERT_DOUBLE_IS_NAN(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
669 #define UNITY_TEST_ASSERT_DOUBLE_IS_DETERMINATE(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
670 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
671 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_NEG_INF(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
672 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_NAN(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
673 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_DETERMINATE(actual, line, message) UNITY_TEST_FAIL((UNITY_LINE_TYPE)line, UnityStrErrDouble)
674 #else
675 #define UNITY_TEST_ASSERT_DOUBLE_WITHIN(delta, expected, actual, line, message) UnityAssertDoublesWithin((_UD)(delta), (_UD)(expected), (_UD)(actual), (message), (UNITY_LINE_TYPE)line)
676 #define UNITY_TEST_ASSERT_EQUAL_DOUBLE(expected, actual, line, message) UNITY_TEST_ASSERT_DOUBLE_WITHIN((_UD)(expected) * (_UD)UNITY_DOUBLE_PRECISION, (_UD)expected, (_UD)actual, (UNITY_LINE_TYPE)line, message)
677 #define UNITY_TEST_ASSERT_EQUAL_DOUBLE_ARRAY(expected, actual, num_elements, line, message) UnityAssertEqualDoubleArray((_UD*)(expected), (_UD*)(actual), (_UU32)(num_elements), (message), (UNITY_LINE_TYPE)line)
678 #define UNITY_TEST_ASSERT_DOUBLE_IS_INF(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_INF)
679 #define UNITY_TEST_ASSERT_DOUBLE_IS_NEG_INF(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NEG_INF)
680 #define UNITY_TEST_ASSERT_DOUBLE_IS_NAN(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NAN)
681 #define UNITY_TEST_ASSERT_DOUBLE_IS_DETERMINATE(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_DET)
682 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_INF(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_INF)
683 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_NEG_INF(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_NEG_INF)
684 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_NAN(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_NAN)
685 #define UNITY_TEST_ASSERT_DOUBLE_IS_NOT_DETERMINATE(actual, line, message) UnityAssertDoubleSpecial((_UD)(actual), (message), (UNITY_LINE_TYPE)line, UNITY_FLOAT_IS_NOT_DET)
686 #endif
687 
688 //End of UNITY_INTERNALS_H
689 #endif
void UnityAssertFloatSpecial(const _UF actual, const char *msg, const UNITY_LINE_TYPE lineNumber, const UNITY_FLOAT_TRAIT_T style)
Definition: unity.c:569
_UU32 _UP
Definition: unity_internals.h:174
Definition: unity_internals.h:338
#define UNITY_FLOAT_TYPE
Definition: unity_internals.h:213
void UnityAssertEqualStringArray(const char **expected, const char **actual, const _UU32 num_elements, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:853
void UnityPrintNumberByStyle(const _U_SINT number, const UNITY_DISPLAY_STYLE_T style)
Definition: unity.c:109
void UnityPrint(const char *string)
Definition: unity.c:77
void UnityAssertEqualIntArray(UNITY_PTR_ATTRIBUTE const void *expected, UNITY_PTR_ATTRIBUTE const void *actual, const _UU32 num_elements, const char *msg, const UNITY_LINE_TYPE lineNumber, const UNITY_DISPLAY_STYLE_T style)
Definition: unity.c:375
void(* UnityTestFunction)(void)
Definition: unity_internals.h:313
void UnityBegin(const char *filename)
Definition: unity.c:1024
Definition: unity_internals.h:366
Definition: unity_internals.h:360
Definition: unity_internals.h:363
Definition: unity_internals.h:344
_UU32 _U_UINT
Definition: unity_internals.h:149
const char UnityStrErr64[]
Definition: unity.c:40
Definition: unity_internals.h:349
UNITY_COUNTER_TYPE CurrentTestFailed
Definition: unity_internals.h:377
const char * TestFile
Definition: unity_internals.h:371
const char UnityStrErrFloat[]
Definition: unity.c:38
void UnityAssertEqualString(const char *expected, const char *actual, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:821
enum _UNITY_FLOAT_TRAIT_T UNITY_FLOAT_TRAIT_T
Definition: unity_internals.h:365
Definition: unity_internals.h:342
Definition: unity_internals.h:364
void UnityAssertEqualNumber(const _U_SINT expected, const _U_SINT actual, const char *msg, const UNITY_LINE_TYPE lineNumber, const UNITY_DISPLAY_STYLE_T style)
Definition: unity.c:355
void UnityIgnore(const char *message, const UNITY_LINE_TYPE line)
Definition: unity.c:975
Definition: unity_internals.h:329
void UnityConcludeTest(void)
Definition: unity.c:258
signed char _US8
Definition: unity_internals.h:117
void UnityAssertFloatsWithin(const _UF delta, const _UF expected, const _UF actual, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:536
void UnityDefaultTestRun(UnityTestFunction Func, const char *FuncName, const int FuncLineNum)
Definition: unity.c:1009
const char * CurrentTestName
Definition: unity_internals.h:372
UNITY_COUNTER_TYPE TestFailures
Definition: unity_internals.h:375
void UnityPrintNumber(const _U_SINT number)
basically do an itoa using as little ram as possible
Definition: unity.c:121
unsigned char _UU8
Definition: unity_internals.h:114
UNITY_FLOAT_TYPE _UF
Definition: unity_internals.h:215
void UnityAssertBits(const _U_SINT mask, const _U_SINT expected, const _U_SINT actual, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:335
#define UNITY_DISPLAY_RANGE_AUTO
Definition: unity_internals.h:318
Definition: unity_internals.h:370
const char UnityStrErrDouble[]
Definition: unity.c:39
UNITY_COUNTER_TYPE CurrentTestIgnored
Definition: unity_internals.h:378
unsigned short _UU16
Definition: unity_internals.h:115
struct _Unity Unity
Definition: unity.c:15
int UnityEnd(void)
Definition: unity.c:1039
unsigned int _UU32
Definition: unity_internals.h:116
#define UNITY_COUNTER_TYPE
Definition: unity_internals.h:289
Definition: unity_internals.h:361
#define UNITY_LINE_TYPE
Definition: unity_internals.h:285
UNITY_COUNTER_TYPE NumberOfTests
Definition: unity_internals.h:374
Definition: unity_internals.h:350
signed short _US16
Definition: unity_internals.h:118
UNITY_COUNTER_TYPE TestIgnores
Definition: unity_internals.h:376
Definition: unity_internals.h:359
void UnityAssertNumbersWithin(const _U_SINT delta, const _U_SINT expected, const _U_SINT actual, const char *msg, const UNITY_LINE_TYPE lineNumber, const UNITY_DISPLAY_STYLE_T style)
Definition: unity.c:786
UNITY_DISPLAY_STYLE_T
Definition: unity_internals.h:320
Definition: unity_internals.h:362
_US32 _U_SINT
Definition: unity_internals.h:150
void UnityFail(const char *message, const UNITY_LINE_TYPE line)
Definition: unity.c:959
signed int _US32
Definition: unity_internals.h:119
Definition: unity_internals.h:354
Definition: unity_internals.h:324
void UnityPrintMask(const _U_UINT mask, const _U_UINT number)
Definition: unity.c:197
Definition: unity_internals.h:328
Definition: unity_internals.h:343
void UnityPrintNumberUnsigned(const _U_UINT number)
basically do an itoa using as little ram as possible
Definition: unity.c:157
#define UNITY_DISPLAY_RANGE_HEX
Definition: unity_internals.h:317
#define UNITY_DISPLAY_RANGE_INT
Definition: unity_internals.h:315
#define UNITY_OUTPUT_CHAR(a)
Definition: unity_internals.h:266
void UnityAssertEqualMemory(UNITY_PTR_ATTRIBUTE const void *expected, UNITY_PTR_ATTRIBUTE const void *actual, const _UU32 length, const _UU32 num_elements, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:903
void UnityPrintNumberHex(const _U_UINT number, const char nibbles)
Definition: unity.c:179
_UNITY_FLOAT_TRAIT_T
Definition: unity_internals.h:358
void UnityAssertEqualFloatArray(UNITY_PTR_ATTRIBUTE const _UF *expected, UNITY_PTR_ATTRIBUTE const _UF *actual, const _UU32 num_elements, const char *msg, const UNITY_LINE_TYPE lineNumber)
Definition: unity.c:483
#define UNITY_DISPLAY_RANGE_UINT
Definition: unity_internals.h:316
UNITY_LINE_TYPE CurrentTestLineNumber
Definition: unity_internals.h:373
jmp_buf AbortFrame
Definition: unity_internals.h:379
Definition: unity_internals.h:348
#define UNITY_PTR_ATTRIBUTE
Definition: unity_internals.h:187
Definition: unity_internals.h:330