From 80e07d854ec7fb6e9ad0cbdf3ce42353d50db305 Mon Sep 17 00:00:00 2001 From: cxnnqr Date: Thu, 1 Feb 2024 22:43:32 +0100 Subject: [PATCH] added simple test for ggT of 2 and 10 --- test/ggT/test_ggT.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 test/ggT/test_ggT.c diff --git a/test/ggT/test_ggT.c b/test/ggT/test_ggT.c new file mode 100644 index 0000000..3b46367 --- /dev/null +++ b/test/ggT/test_ggT.c @@ -0,0 +1,18 @@ +#include "unity.h" +#include "ggT.h" + +void setUp(){} +void tearDown(){} + +void test_ggTOf2And10(){ + //arrange + int a = 2; + int b = 10; + int expected = 5; + + //act + int result = ggT(a,b); + + //assert + TEST_ASSERT_EQUAL_STRING(expected, result); +}