Commit Graph

1111 Commits

Author SHA1 Message Date
wolf99
8b90b51c68 Reference style URLs 2021-06-02 23:13:14 +01:00
wolf99
d0b5a920bb markdown conformance 2021-06-02 22:49:03 +01:00
Mark VanderVoord
1a681340de Merge pull request #564 from BAUR-GmbH/master
Use stdnoreturn.h for c11 and [[ noreturn ]] for c++11. Fixes #563
2021-06-02 11:42:32 -04:00
Bernhard Breuß
f944b08878 Use stdnoreturn.h for c11 and [[ noreturn ]] for c++11. ThrowTheSwitch#563 2021-06-02 16:56:14 +02:00
Mark VanderVoord
bd3c7dfd0d Merge pull request #562 from kisvegabor/patch-1
Fix typo in UnityHelperScriptsGuide.md (Thanks @kisvegabor !)
2021-06-02 09:52:45 -04:00
Gabor Kiss-Vamosi
fa5644bd07 Fix typo in UnityHelperScriptsGuide.md
An `e` is missing in`suit_setup` in the `my_config.yml`.
2021-06-02 15:38:27 +02:00
Mark VanderVoord
7d37a8e11e Merge pull request #561 from druckdev/master
Support `UNITY_INCLUDE_EXEC_TIME` under Apples OSX
2021-05-31 11:04:01 -04:00
druckdev
edfc5ae355 Support UNITY_INCLUDE_EXEC_TIME under Apples OSX
The unix way of getting the time works under OSX as well and can be
used.
2021-05-31 12:55:37 +02:00
Mark VanderVoord
61f4428435 Merge pull request #543 from farrrb/bugfix/fix-issue-531
Enable __attribute__ when __clang__ is definedgit
2021-02-26 13:01:42 -05:00
Fabian Zahn
0168ea1541 Enable __attribute__ when __clang__ is definedgit 2021-02-26 18:46:27 +01:00
Mark VanderVoord
ccd7ca72f3 Merge pull request #542 from farrrb/patch-1
Update UnityConfigurationGuide.md
2021-02-26 07:38:47 -05:00
Fabian Zahn - 0xFAB
66cec22838 Update UnityConfigurationGuide.md
Add semi-colon to configuration :)
2021-02-26 07:51:57 +01:00
Mark VanderVoord
74cde089e6 Merge pull request #540 from numaru/master
Enlarge the TEST_RANGE() regex to accept more spaces (Thanks for the help, @numaru !)
2021-02-12 15:42:25 -05:00
Kin Numaru
63fef7dd10 Enlarge the TEST_RANGE() regex to accept more spaces
This commit change the regex to accept more spaces inside the brackets
of the TEST_RANGE().

I use clang-format through vscode "editor.formatOnSave": true feature and it produce
padding spaces inside the array brackets by default.

```c
int a[] = [1, 2];
```

is changed into

```c
int a[] = [ 1, 2 ];
```

Also, every time I save a file containing a TEST_RANGE() with ctrl + s,
it breaks it.
2021-02-12 20:39:05 +01:00
Mark VanderVoord
78dea55ba5 Merge pull request #539 from Borowiec-B/master
Fix typo in doc (Thanks Michael!)
2021-02-10 09:28:45 -05:00
throwaway47912
563b93e5ec Fix typo in doc 2021-02-10 15:20:03 +01:00
Mark VanderVoord
0b899aec14 Fix conditional issue in generator script.
Bump version.
v2.5.2
2021-01-26 08:59:27 -05:00
Mark VanderVoord
d8eb8414f4 Stop noticing my sublime files. ;) 2021-01-16 21:20:09 -05:00
Mark VanderVoord
05994f5061 Merge pull request #536 from ThrowTheSwitch/test/switch_to_actions
Attempt to get Actions Working
2021-01-16 21:05:49 -05:00
Mark VanderVoord
fcab680286 Ruby script cleanup.
Fix warnings.
Remove 32-bit tests from standard suite because they're not running on most platforms.
2021-01-16 21:03:18 -05:00
Mark VanderVoord
3c1c5338af Need to checkout.
Drop Slack support
2021-01-16 20:27:49 -05:00
Mark VanderVoord
9e7c259822 Do we need to be admin to install gems? 2021-01-16 20:19:29 -05:00
Mark VanderVoord
ce132da37f Merge pull request #535 from ThrowTheSwitch/test/switch_to_actions
Switch from Travis to Github Actions.
2021-01-16 20:15:22 -05:00
Mark VanderVoord
ffb51ecb7e Switch from Travis to Github Actions.
Update year in docs.
2021-01-16 20:05:20 -05:00
Mark VanderVoord
0b078cdb6e Merge pull request #533 from carsonalh/master
Fixed CMake install when compiled with extensions
2021-01-08 09:01:41 -05:00
Carson Holloway
53e1449f89 Fixed CMake install when compiled with extensions
This is a fix from the change I made in
`commit 418c1635f2f1bcd353b6fce23a16594c914047b8`
where I added options to compile unity with the `fixture` and `memory`
extensions:

In that version, Unity had been able to build, but there were some issues when
trying to install it. Namely, the CMake generator expressions were not
evaluated correctly, and it would try to install with a path that had
un-expanded generator commands in it, which would obviously fail and throw an
error. I've got a feeling that this is a bug with CMake, but for now the
workaround that worked in [this stackoverflow
post](https://stackoverflow.com/questions/51541678/nested-cmake-generator-expressions-are-only-partially-evaluated)
seemed to work here, as well.

Another issue with that commit was that it tried to include a
`unity_memory_internals.h` file, which did not exist. This has also been
resolved.
2021-01-08 10:34:38 +10:00
Mark VanderVoord
830f77f9ee Merge pull request #509 from alecoding/issue_507
Fix warning for issue #507
2021-01-07 18:08:51 -05:00
Mark VanderVoord
038dd81213 Merge pull request #520 from softwareinmotion/runner_mock_suffix
parse mock files correctly
2021-01-07 18:08:09 -05:00
Mark VanderVoord
99fb90a939 Merge pull request #522 from JuPrgn/master
Add guard TEST on test module template
2021-01-07 18:05:48 -05:00
Mark VanderVoord
b7469138a5 Merge pull request #530 from carsonalh/master
Added options to compile "fixture" and "memory" extensions in CMakeLists
2021-01-07 18:05:05 -05:00
Carson Holloway
418c1635f2 Added option to compile fixture and memory extensions in CMakeLists.txt 2020-12-20 12:58:11 +11:00
Mark VanderVoord
386c540510 Merge pull request #524 from sardior/exlude-details-compile-fix
Update unity.c
2020-10-12 08:36:48 -04:00
Robert Sławomir Kőműves
723b9fee53 Update unity.c
UNITY_EXCLUDE_DETAILS caused a compile error here due to UNITY_DETAIL{1,2}_NAME declaration already being skipped.
2020-10-08 00:55:47 +02:00
Julien PEYREGNE
76c3755fe3 Add guard TEST on test module template
With a test file guarded we can include this file on IDE project
(MPLAB X in my case) and compile without excluding test files.
Excluding test files on MPLAB X disable autocompletion and function
navigation.
2020-09-07 10:37:26 +02:00
Fabian Weik
c3afe99a77 parse mock files correctly 2020-08-27 13:21:45 +02:00
Mark VanderVoord
98045925af Merge pull request #514 from michaelbrockus/let_meson_handle_flags
Let meson handle flags
2020-08-06 06:37:48 -04:00
Michael Brockus
62d0e7d68e Update meson.build 2020-08-05 21:15:37 -07:00
Michael Brockus
52d5f59b72 Update meson.build 2020-08-05 21:13:06 -07:00
Mark VanderVoord
09acb0b64f Merge pull request #513 from carsonalh/msvcfix
Fix for MSVC compilation errors
2020-07-18 10:37:51 -04:00
Carson Holloway
e640949eb3 Patched compilation error for MSVC. 2020-07-18 21:59:55 +10:00
Carson Holloway
6fecc8eb38 Added MSVC options to CMakeLists.txt. 2020-07-18 21:58:54 +10:00
Carson Holloway
777ad17420 Added MSVC options to CMakeLists.txt. 2020-07-18 21:52:00 +10:00
Alessio Centazzo
8bbfe1f5ac Fix warning from issue #507
UnityFail() and UnityIgnore had the noreturn attribute with long jumps disabled
2020-06-06 08:07:57 -07:00
Mark VanderVoord
0126e4804c Merge pull request #504 from phyrwork/master
Fix TEST_ASSERT_BIT(S)_HIGH testing only lower 32-bits (Thanks @phyrwork !)
2020-05-26 08:04:03 -04: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
fedd1495c2 Merge pull request #503 from andred/master
unity: annotate noreturn APIs (fix Wsuggest-attribute=noreturn warnings)
2020-05-25 11:09:55 -04:00
André Draszik
a6a4e9766d unity: annotate noreturn APIs (fix Wsuggest-attribute=noreturn warnings)
GCC (& Clang) have the notion of pure and const functions [1],
where those attributes are intended to help the optimiser.

Annotate a few APIs here with the appropriate key words, which
also fixes Wsuggest-attribute=noreturn warning, which a
source base might have enabled:
Compiling unity.c...
.../src/unity.c: In function ‘UnityFail’:
.../src/unity.c:1759:6: warning: function might be candidate for attribute ‘noreturn’ [-Wsuggest-attribute=noreturn]
 1759 | void UnityFail(const char* msg, const UNITY_LINE_TYPE line)
      |      ^~~~~~~~~
.../src/unity.c: In function ‘UnityIgnore’:
.../src/unity.c:1796:6: warning: function might be candidate for attribute ‘noreturn’ [-Wsuggest-attribute=noreturn]
 1796 | void UnityIgnore(const char* msg, const UNITY_LINE_TYPE line)
      |      ^~~~~~~~~~~

[1] https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html

Signed-off-by: André Draszik <git@andred.net>
2020-05-25 15:49:47 +01:00
Mark VanderVoord
06a668579f Merge pull request #501 from andred/master
allow compilation with stricter warnings (Thanks @andred !)
2020-05-25 06:59:32 -04:00
André Draszik
9760c4f14f unity: fix Wswitch-enum warning
Compiling a source base / test with Wswitch-enum enabled, gives
the following warning:

../src/unity.c: In function ‘UnityAssertFloatSpecial’:
../src/unity.c:1092:5: warning: enumeration value ‘UNITY_FLOAT_INVALID_TRAIT’ not handled in switch [-Wswitch-enum]
 1092 |     switch (style)
      |     ^~~~~~

Fix by adding the missing value to the default (unhandled) case.

Signed-off-by: André Draszik <git@andred.net>
2020-05-25 08:58:37 +01:00
André Draszik
f5ff3504b5 auto/run_test: fix Wsign-compare warning
Compiling a source base / test with Wsign-compare enabled, gives
the following warning:

build/test/runners/test_system_runner.c: In function ‘run_test’:
build/test/runners/test_system_runner.c:62:35: warning: conversion to ‘UNITY_UINT’ {aka ‘long unsigned int’} from ‘int’ may change the sign of the result [-Wsign-conversion]
   62 |     Unity.CurrentTestLineNumber = line_num;
      |                                   ^~~~~~~~

Fix by updating the type in the function declaration.

Signed-off-by: André Draszik <git@andred.net>
2020-05-25 07:14:14 +01:00