From 879d2e9b919def495ad64c0526e234a4f455ff19 Mon Sep 17 00:00:00 2001 From: Leonetienne Date: Fri, 11 Feb 2022 11:19:25 +0100 Subject: [PATCH] Translated Math/Clamp test --- Test/CMakeLists.txt | 1 + Test/Math_Abs.cpp | 39 --------------------------------------- 2 files changed, 1 insertion(+), 39 deletions(-) delete mode 100644 Test/Math_Abs.cpp diff --git a/Test/CMakeLists.txt b/Test/CMakeLists.txt index b01345c..b2d6e11 100644 --- a/Test/CMakeLists.txt +++ b/Test/CMakeLists.txt @@ -12,6 +12,7 @@ add_executable(Tests Math__Mod.cpp Math__Oscillate.cpp Math__Abs.cpp + Math__Clamp.cpp ) target_link_libraries(Tests Eule) diff --git a/Test/Math_Abs.cpp b/Test/Math_Abs.cpp deleted file mode 100644 index 6a885eb..0000000 --- a/Test/Math_Abs.cpp +++ /dev/null @@ -1,39 +0,0 @@ -#include "CppUnitTest.h" -#include "../Eule/Math.h" - -using namespace Microsoft::VisualStudio::CppUnitTestFramework; -using namespace Eule; - -/** Equivalence classes: -* -- value > 0 -* -- value < 0 -* -- value == 0 -*/ - -namespace _Math -{ - TEST_CLASS(_Abs) - { - public: - // Checks with a positive input - TEST_METHOD(Positive_Value) - { - Assert::AreEqual(45.0, Math::Abs(45.0)); - return; - } - - // Checks with a negative input - TEST_METHOD(Negative_Value) - { - Assert::AreEqual(45.0, Math::Abs(-45.0)); - return; - } - - // Checks with a zero input - TEST_METHOD(Zero_Value) - { - Assert::AreEqual(0.0, Math::Abs(0.0)); - return; - } - }; -}