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.
 
 
 

38 lines
730 B

#include "unity.h"
#include "kgV.h"
#include "ggT.h"
void setUp(void){}
void tearDown(void){}
void test_kgV8And6(void) {
TEST_ASSERT_EQUAL_INT(24, kgV(8, 6));
}
void test_kgVOfFirstNumberZero(){
TEST_ASSERT_EQUAL_INT(0, kgV(0, 5));
}
void test_kgVOfSecondNumberZero(){
TEST_ASSERT_EQUAL_INT(0, kgV(5, 0));
}
void test_kgVOfBothNumbersZero(){
TEST_ASSERT_EQUAL_INT(0, kgV(0, 0));
}
void test_kgVOf2And17(){
TEST_ASSERT_EQUAL_INT(34, kgV(2, 17));
}
void test_kgVOfFirstNumberNegative(){
TEST_ASSERT_EQUAL_INT(34, kgV(-2, 17));
}
void test_kgVOfSecondNumberNegative(){
TEST_ASSERT_EQUAL_INT(34, kgV(2, -17));
}
void test_kgVOfBothNumbersNegative(){
TEST_ASSERT_EQUAL_INT(34, kgV(-2, -17));
}