Exploring raycasters and possibly make a little "doom like" game based on it.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
raycaster/tests/easings.cpp

17 lines
383 B

#include <catch2/catch_test_macros.hpp>
#include "easings.hpp"
#include <cmath>
TEST_CASE("make sure the easing functions at least run", "[easings]") {
double out = ease::sine(1.3);
REQUIRE(out <= 1.0);
out = ease::out_circ(3.444);
REQUIRE(std::isnan(out));
out = ease::out_bounce(1.13);
REQUIRE(out <= 10 );
out = ease::in_out_back(3.4);
REQUIRE(out < 250.0);
}