Commit Graph

66 Commits (e161795071f58fe746a2b9e1238ac2c3c8681dae)

Author SHA1 Message Date
Pierre Wendling 2ec48b36ba Test: Fix OS/2 compilation in math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 43c22e5d1e Test: Refactor math suite duplicate code.
Many tests were using the same underlying routine, as such three helper
functions were added:
- A wrapper to test double -> double functions.
- A wrapper to test (double, double) -> double functions,
- A wrapper for range tests on double -> double functions.
2022-06-15 12:05:30 -07:00
Pierre Wendling 3d720ba381 Test: Refactor math suites edge cases.
Split infinity and zero checks in their own functions.
The result of NAN tests is now logged.
The SDL_TestCaseReference structure were renamed to be more explicit.
2022-06-15 12:05:30 -07:00
Pierre Wendling a530fc9199 Test: Add Copysign tests to math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 48a406db4d Test: Add Fabs tests to math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 2130dff0fc Test: Add Round tests to math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 324b96153f Test: Add Trunc tests to math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling b09266a4ef Test: Add Ceil tests to math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 9eb09d2392 Test: Refactored and formatted math test suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling e64acb619a Test: Fix for-loop for OS/2 in math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling a3a852e912 Test: Unrolled the array of cases in math suite.
On OS/2, `INFINITY` is a `const double` which cannot be used to
instantiate an array.
2022-06-15 12:05:30 -07:00
Pierre Wendling c23216bf46 Test: Removed static from local variables (Math).
Static would break compilation on OS/2.
2022-06-15 12:05:30 -07:00
Pierre Wendling 6646edf692 Test: Fix Windows build for math suite. 2022-06-15 12:05:30 -07:00
Pierre Wendling 7389eba943 Test: Fix C89 declaration and math include. 2022-06-15 12:05:30 -07:00
Pierre Wendling b3faebb8a8 Test: Add Floor tests to math. 2022-06-15 12:05:30 -07:00
Pierre Wendling b72b5d0f99 Test: Add math automation test suite. 2022-06-15 12:05:30 -07:00