Jonathan Reichelt Gjertsen
b732fbf1ca
Add LESS_OR_EQUAL and GREATER_OR_EQUAL assertions for doubles and floats
2021-12-03 20:39:55 +01:00
Jonathan Reichelt Gjertsen
244edf6c16
Add NOT_EQUAL* and NOT_WITHIN* checks for floats and doubles
2021-12-03 19:53:31 +01:00
Jonathan Reichelt Gjertsen
5a3d82bda6
Merge branch 'master' into more-float
2021-12-03 18:23:22 +01:00
Mark VanderVoord
8ba0138600
Merge pull request #544 from farrrb/bugfix/fix-issue-510
...
Bugfix/fix issue 510
2021-12-03 10:58:29 -05:00
Jonathan Reichelt Gjertsen
d06ac64852
Merge remote-tracking branch 'upstream/master' into more-float
...
# Conflicts:
# README.md
# docs/UnityAssertionsReference.md
2021-07-27 01:54:26 +02:00
Mark VanderVoord
2f7406572e
Bump Version
2021-06-18 14:32:54 -04:00
Mark VanderVoord
e44c3b56f7
Adjust how decimal tracking handles to avoid warnings.
2021-06-03 08:51:24 -04:00
Jonathan Reichelt Gjertsen
410de1a02b
Add macros for testing inequalities between floats, doubles
2021-05-24 17:02:58 +02:00
Fabian Zahn
7edf9d9ac5
Fix #510 (-Wextra-semi-stmt with clang compiler)
2021-02-27 08:53:53 +01:00
Mark VanderVoord
0b899aec14
Fix conditional issue in generator script.
...
Bump version.
2021-01-26 08:59:27 -05:00
Mark VanderVoord
ffb51ecb7e
Switch from Travis to Github Actions.
...
Update year in docs.
2021-01-16 20:05:20 -05:00
Connor Newton
b4b1994bd7
Fix TEST_ASSERT_BIT(S)_HIGH testing only lower 32-bits
...
The high/low bits masks for TEST_ASSERT_BIT(S)_HIGH/LOW are created
by casting 0/-1 to UNITY_UINT32. This isn't OK on 64-bit platforms
as it results in a high bits mask of 0x00000000ffffffff instead of
0xffffffffffffffff.
Cast 0/-1 to UNITY_UINT instead.
2020-05-26 12:58:14 +01:00
Mark VanderVoord
cf949f45ca
Bump Version
2020-05-03 16:03:07 -04:00
mvandervoord
71e77ce6fb
Added NOT-EQUAL int variants.
...
Organized Unit Tests
2020-03-16 18:45:40 -04:00
mvandervoord
bad429428d
Add assertion for checking empty null-terminated arrays. This is particularly useful for check c strings.
2020-03-16 15:04:40 -04:00
Jørn Villesen Christensen
3da0b4652c
Implement macro TEST_PRINTF: Works like TEST_MESSAGE, but with a format-string.
...
Depends on UnityPrintFormatted (define UNITY_INCLUDE_PRINT_FORMATTED).
UnityPrintFormatted has been renamed to UnityPrintF due to changes below.
API of UnityPrintFormatted has been changed (hence the rename), but end users
(developers) can use the TEST_PRINTF as an almost-drop-in replacement TEST_PRINTF
is compatible with the old UnityPrintFormatted API (see below).
The behaviour of UnityPrintF has also been changed:
- Now it prefixes the outout with test location information Output is marked
as INFO.
- It adds an EOL.
Both behaviours adopted from other output functions.
2020-02-14 22:43:51 +01:00
mvandervoord
354e2b4da6
Added set of assertions for checking CHAR's and CHAR arrays (not as strings)
2019-10-28 16:54:32 -04:00
mvandervoord
be87d790c7
Add verifyTest option to go with resetTest.
...
Fix docs.
2019-10-28 10:32:22 -04:00
Mark VanderVoord
d9b0edf282
Switch from the inconsistent use of weak symbols to handling setup, etc in script generators
2019-10-21 14:21:52 -04:00
Mark VanderVoord
9842a4d03d
Switching to universal version being in the header file itself.
2019-10-21 10:12:59 -04:00
Mark VanderVoord
77008edca9
Support size_t macros
2019-10-21 08:32:35 -04:00
Mark VanderVoord
0000f1e6d2
Add TEST_MESSAGE for outputting messages without aborting a test and _MESSAGE variant to TEST_PASS collection.
2019-07-06 11:02:32 -04:00
Mark VanderVoord
c30730faf6
cleanup warning.
2019-07-03 15:07:44 -04:00
Mark VanderVoord
f2d826c7c5
- Added options for how to handle TEST_ASSERT_EQUAL shorthand
...
- Tweak a couple style problems with Ruby scripts.
2019-07-03 15:03:03 -04:00
Mark VanderVoord
2b0d093837
Merge pull request #403 from farrrb/fix-issue-392
...
Used sizeof operator for pointer increments in UnityAssertEqualIntArray().
2019-05-04 07:39:22 -04:00
Dom Postorivo
9340582797
ARRAY_WITHIN in unity
2019-04-20 14:10:56 -04:00
Fabian Zahn
d01e32299e
Used sizeof() operator for pointer increments and substituted sizeof() operator for the unsigned int mask calculation to "UNITY_INT_WIDTH / 8" in function "UnityAssertEqualIntArray".
2019-04-07 18:34:25 +02:00
Roland Stahn
6a1d2e8d44
Fix LESS_OR_EQUAL_MESSAGE asserts for HEX32/HEX64
...
Macros TEST_ASSERT_LESS_OR_EQUAL_HEX32_MESSAGE() and TEST_ASSERT_LESS_OR_EQUAL_HEX64_MESSAGE() need to be mapped to UNITY_TEST_ASSERT_SMALLER_OR_EQUAL_HEXnn() instead of UNITY_TEST_ASSERT_SMALLER_THAN_HEXnn()
2018-07-25 22:57:44 +02:00
Mark VanderVoord
774da10e00
Merge pull request #296 from jlindgren90/master
...
Allow suiteSetUp() and suiteTearDown() to be provided as normal C functions (Thanks @jlindgren90 )
2017-11-04 09:04:53 -04:00
John Lindgren
629b86d541
Merge unity_setup.h into unity.h.
2017-11-01 11:36:26 -04:00
Kate Hart
5ee55fefda
Fix missing TEST_ASSERT_EACH_EQUAL_HEX_MESSAGE
2017-10-30 17:44:32 -07:00
jsalling
b119919c4f
Add 64-bit comparison asserts
2017-09-20 18:26:17 -05:00
jsalling
91bcbe186d
Add 'greater/less or equal to' asserts on integers
...
Make all comparison operators on integers available
2017-09-20 18:24:23 -05:00
John Lindgren
2593c31bb7
Allow suiteSetUp() and suiteTearDown() to be provided as normal C functions.
...
This is simpler and more flexible than embedding C code in the Ruby options
(:suite_setup and :suite_teardown). However, support for :suite_setup and
:suite_teardown is kept for backwards compatibility.
Several configurations are possible:
1. :suite_setup and :suite_teardown options provided and used.
2. :suite_setup and :suite_teardown options not provided (nil):
2a. Weak symbols not supported; suiteSetUp() and suiteTearDown() are not called.
It would be simpler to make user-provided functions mandatory in this case,
but it could break some pre-existing test suites.
2b. Weak symbols are supported and the stub implementations of suiteSetUp() and
suiteTearDown() are called if there are no user-provided functions.
2c. Weak symbols are supported but overridden by user-provided suiteSetUp() and
suiteTearDown() functions.
2017-09-13 18:12:23 -04:00
Dom Postorivo
f2fdf1a133
Added Greater than and Less than asserts from other PR
2017-05-13 15:59:51 -04:00
Mark VanderVoord
0dddf498c2
also update strings to support each element of an array.
2017-03-21 23:57:15 -04:00
Mark VanderVoord
a11a13750d
Added memory each equal assertion
2017-03-21 18:28:49 -04:00
Mark VanderVoord
d8d67a708c
Added each_equal assertions for float and double
2017-03-21 17:05:19 -04:00
Mark VanderVoord
7fe31915d0
Added some tests to prove this works. Still work in progress
2017-03-21 14:37:52 -04:00
Mark VanderVoord
41ee499e63
Tiny tweaks to make Unity fit in more smoothly with Ceedling
2017-03-13 16:46:41 -04:00
jsalling
5449f1e4d1
Condense all longjmp calls into TEST_ABORT()
...
The setjmp calls are all in TEST_PROTECT() already
2017-01-14 10:41:03 -06:00
jsalling
b0870ec8b9
Merge branch 'feature/print-floats'
...
Fix new type name conflicts
Conflicts:
src/unity.c
src/unity_internals.h
2016-12-15 21:15:30 -06:00
Mark VanderVoord
8e31f5d869
Revised internal type naming scheme to better sandbox Unity away from everything else. Sure, short was nice, but not at the expense of naming collisions.
2016-11-29 08:38:51 -05:00
jsalling
47f6a85b8c
Make UnityPrintFloat on by default
...
Remove UNITY_FLOAT_VERBOSE entirely, add option UNITY_EXCLUDE_FLOAT_PRINT
Remove some questionable float casts from doubles
Default to Round Ties to Even behavior, add option to Round Ties Away from Zero
2016-11-19 13:52:24 -06:00
jsalling
28c94bd403
Remove references to UNITY_EXCLUDE_SIZEOF, rework config header
2016-08-25 08:48:29 -05:00
Mark VanderVoord
f05385250c
- Document new define in unity.h. Will still need to be added to real docs
2016-07-08 16:10:14 -04:00
Andrzej Bieniek
61dd3f181b
Change comments style in unity and test runner to compile with std=c89
2016-05-15 14:35:50 +01:00
jsalling
c5238adab2
100% code coverage for Unity project
...
Add test for failure count and UnityEnd return value
Cover printing escape codes with length parameter
Full statement coverage
2016-05-03 21:58:29 -05:00
jsalling
0137f4a8c2
Add option to print FAILED instead of FAIL during the summary
...
For easier automation and searching for a test suite failure
2016-04-27 21:00:04 -05:00
Mark VanderVoord
a7f81e8a04
Merge pull request #172 from pacheco017/UnityPrintFloat-overflow-fixes
...
UnityPrintFloat overflow fixes. (Thanks pacheco017!)
2016-02-24 20:16:45 -05:00