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.

31 lines
465 B

  1. #include "unity.h"
  2. #include "ggT.h"
  3. void setUp(){}
  4. void tearDown(){}
  5. void test_ggTOf5And10(){
  6. //arrange
  7. int a = 5;
  8. int b = 10;
  9. int expected = 5;
  10. //act
  11. int result = ggT(a,b);
  12. //assert
  13. TEST_ASSERT_EQUAL_INT(expected, result);
  14. }
  15. void test_ggTOf0AndPositiveNumber(){
  16. //arrange
  17. int a = 0;
  18. int b = 5;
  19. int expected = 5;
  20. //act
  21. int result = ggT(a,b);
  22. //assert
  23. TEST_ASSERT_EQUAL_INT(expected, result);
  24. }