11 lines
287 B
C++
11 lines
287 B
C++
#include "factorial.h"
|
|
#include <catch2/catch_test_macros.hpp>
|
|
|
|
TEST_CASE("Factorials are computed", "[factorial]") {
|
|
REQUIRE(Factorial(0) == 1);
|
|
REQUIRE(Factorial(1) == 1);
|
|
REQUIRE(Factorial(2) == 2);
|
|
REQUIRE(Factorial(3) == 6);
|
|
REQUIRE(Factorial(10) == 3628800);
|
|
}
|