aboutsummaryrefslogtreecommitdiffstats
path: root/.conan/test_package/test_package.cpp
diff options
context:
space:
mode:
authorLexi Winter <lexi@le-fay.org>2025-06-29 19:25:29 +0100
committerLexi Winter <lexi@le-fay.org>2025-06-29 19:25:29 +0100
commitbc524d70253a4ab2fe40c3ca3e5666e267c0a4d1 (patch)
tree1e629e7b46b1d9972a973bc93fd100bcebd395be /.conan/test_package/test_package.cpp
downloadnihil-bc524d70253a4ab2fe40c3ca3e5666e267c0a4d1.tar.gz
nihil-bc524d70253a4ab2fe40c3ca3e5666e267c0a4d1.tar.bz2
Diffstat (limited to '.conan/test_package/test_package.cpp')
-rw-r--r--.conan/test_package/test_package.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/.conan/test_package/test_package.cpp b/.conan/test_package/test_package.cpp
new file mode 100644
index 0000000..3c08090
--- /dev/null
+++ b/.conan/test_package/test_package.cpp
@@ -0,0 +1,13 @@
+#include <catch2/catch_test_macros.hpp>
+
+int Factorial( int number ) {
+ return number <= 1 ? 1 : Factorial( number - 1 ) * number;
+}
+
+TEST_CASE( "Factorial Tests", "[single-file]" ) {
+ REQUIRE( Factorial(0) == 1 );
+ REQUIRE( Factorial(1) == 1 );
+ REQUIRE( Factorial(2) == 2 );
+ REQUIRE( Factorial(3) == 6 );
+ REQUIRE( Factorial(10) == 3628800 );
+} \ No newline at end of file