Commit Graph

26 Commits

Author SHA1 Message Date
Chris Thrasher
49fd5887c8 Add tests for SFML/Config.hpp 2022-08-03 23:39:37 +02:00
Chris Thrasher
a47eb8320a Remove vendored doctest header 2022-07-20 08:56:59 +02:00
Chris Thrasher
4f52793f7d Run clang-format 2022-07-11 20:04:56 +02:00
metaquarx
88e9f82bee Add '.clang-format' file, CI integration, and formatting exceptions
Co-authored-by: Vittorio Romeo <vittorio.romeo@outlook.com>
Co-authored-by: Chris Thrasher <chrisjthrasher@gmail.com>
Co-authored-by: kimci86 <kimci86@hotmail.fr>
2022-07-11 20:04:56 +02:00
Bambo-Borris
c6f7fcaa2a Add tests for sf::MemoryInputStream 2022-06-28 14:33:21 +02:00
Chris Thrasher
fd3526f742 Use <> for test utilities includes
SFML convention is to only use "" includes when the header is in
the same directory as the file including it. Because these test
util headers are in a separate directory, it makes more sense to
include them via <>.
2022-06-27 00:22:16 +02:00
Chris Thrasher
44d3d63ade Reduce the scope of helper class 2022-06-26 02:14:53 +02:00
Vittorio Romeo
8a2aa6397f Explicitly instantiate float vector members in cpp 2022-06-24 18:47:28 +02:00
Chris Thrasher
7dd001e5c0 Simplify approximate comparisons of SFML types
Co-authored-by: kimci86 <kimci86@hotmail.fr>
2022-05-25 13:36:12 +02:00
Chris Thrasher
88515b2fca Add polar coordinates constructor for sf::Vector2<T> 2022-05-17 20:30:02 +02:00
Bambo-Borris
b2ab6d6ab3 Add extension methods to Vector3<T>
Includes relevant tests and updates TestUtilities to feature ApproxVec2 & ApproxVec3
2022-05-16 08:59:42 +02:00
Chris Thrasher
c0a6cf1f0c Remove unnecessary lossy conversions in test utilities
Both ApproxVec and ApproxDeg accept a double then convert that to
a float just to then convert it back to a double. We can save an
extra lossy conversion by just accepting a float instead of a double
in the first place.
2022-05-04 09:03:04 +02:00
Chris Thrasher
1e560ababd Add tests for sf::err 2022-05-02 09:53:04 +02:00
Chris Thrasher
2a5ce3c989 Apply compiler warnings to tests 2022-05-02 08:39:02 +02:00
Jan Haller
28e935673c Const-qualify local variables in Vector2 test, where possible 2022-02-28 16:18:00 +00:00
Jan Haller
2eef193c0e Unit tests for Vector2 extensions
Also adds ApproxVec and ApproxDeg types for more readable comparison of approximate vectors/angles.
2022-02-28 16:18:00 +00:00
Chris Thrasher
ec4ac1afc4 Remove GCC 8 workarounds 2022-02-17 00:40:29 +00:00
Vittorio Romeo
63ce7e4e92 Remove unnecessary includes from public-facing headers 2022-02-10 21:05:49 +00:00
Chris Thrasher
28f273b9c9 Add sf::Angle
Similar to sf::Time, sf::Angle provides a typesafe API for working
with angles and provides named functions for converting to and from
degrees and radians.
2022-02-08 22:52:37 +00:00
Chris Thrasher
da6a226941 Add tests for sf::Clock 2022-01-11 22:49:00 +00:00
Chris Thrasher
3d01efb80a Use operator<< for printing during test failure 2022-01-07 20:04:54 +01:00
Chris Thrasher
3197dc8029 Remove redundant formatters 2022-01-03 08:27:43 +01:00
Vittorio Romeo
3dc8fc0923 Add 'NetworkUtil' for network module tests 2022-01-03 01:00:55 +01:00
Vittorio Romeo
5ba6580568 Make 'Time' a 'constexpr' class 2021-12-28 16:52:52 +01:00
Vittorio Romeo
29983aa8d4 Replace Catch with Doctest 2021-12-24 15:06:32 +01:00
Chris Thrasher
ade9843dd8 Collapse test/src directory 2021-12-24 11:56:58 +01:00