Commit Graph

18 Commits

Author SHA1 Message Date
Benjamin Vedder b900ffcde5 Orginized files 2022-05-15 11:55:34 +02:00
Kenn Sebesta 571f8d1d0e [Unit test][Utils] Add unit test for `utils_saturate_vector_2d()` 2022-03-25 09:41:02 -04:00
Kenn Sebesta 484215c2e6 [Unit tests][Utils_math] Use `EXPECT_FLOAT_EQ` instead of `EXPECT_NEAR`
EXPECT_FLOAT_EQ verifies that the two float values val1 and val2 are
approximately equal, to within 4 ULPs from each other. (Where ULP means
Unit in the Last Place.)
2022-03-25 09:06:55 -04:00
Kenn Sebesta a85f1252f5 [Unit test] Adjust values in and out of range
The contract is `-pi <= angle < pi`
2022-03-25 09:04:18 -04:00
Kenn Sebesta 52c15f3988 [Unit test] Add warning for promotion to double
This mirrors the real compiler settings.
2022-03-25 09:04:18 -04:00
Kenn Sebesta c32f70758c [Unit tests][Utils] Improve comments and test cases 2022-03-25 08:39:53 -04:00
Kenn Sebesta 754a8460e2 [Unit tests][Utils_math] Fix test ranges
Now that the `utils_norm_angle_rad()` range was fixed, change the unit test
to reflect the correct [-pi,pi) range.
2022-03-25 08:20:52 -04:00
Kenn Sebesta caed3de872 [Unit tests][Utils_math] Fix file paths
The unit test location is `utils_math.c/.h` not `math_utils.c/.h`.
2022-03-25 08:19:29 -04:00
Kenn Sebesta af2b278a8b [Unit tests][Utils_math] Fix location
The unit test location is `utils_math` not `math_utils`.
2022-03-25 08:17:57 -04:00
Kenn Sebesta 3d966c1e4f [Utils][Unit test] Point the unit test toward the new math_utils.c/.h 2022-03-23 20:25:37 -04:00
Kenn Sebesta a4f4f7a6f3 [Sys utils] Remove unit test cruft
This #define became unnecessary once this function was split from the
math functions
2022-03-23 20:25:37 -04:00
Kenn Sebesta ecf2c9a5b0 [Unit test] Use compiler-specific double-->single flags
Not all compilers support `-fsingle-precision-constant`
2022-03-14 13:15:55 -04:00
Kenn Sebesta 5819b87299 [Unit tests][Utils.c] Fix unit test compilation
The test compilation were broken by the addition of some threading
utilities.
2022-03-06 12:35:51 -05:00
Kenn Sebesta 7285114b9d [Unit tests] Add unit test for `utils.c`.
Note that in order to satisfy some header files in `utils.c`, there are
some dummy functions in local dummy files.
2022-03-02 16:56:17 -05:00
Benjamin Vedder f0b291d4eb Improved overvoltage protection 2021-11-10 14:19:48 +01:00
Benjamin Vedder 5742d1baf1 Handle subnormal numbers in float serialization 2021-06-09 19:20:48 +02:00
Benjamin Vedder b412ac3ccd Moved packet handler state to caller and updated unit test for packet handler 2021-01-12 23:15:01 +01:00
Benjamin Vedder 123bb00ab4 Major 2019 update 2019-02-18 19:30:19 +01:00