diff --git a/src/bmi.c b/src/bmi.c index f363258..b915b22 100644 --- a/src/bmi.c +++ b/src/bmi.c @@ -25,7 +25,7 @@ const char* retResult(float points){ return "Starkes Uebergewicht"; } -int main() +int run_bmi() { float var1 = 0; float var2 = 0; diff --git a/src/bmi.h b/src/bmi.h index b1a92c8..ac463e0 100644 --- a/src/bmi.h +++ b/src/bmi.h @@ -2,5 +2,6 @@ #define BMI_H float calcBMI(float height, float weight); +const char* retResult(float points); #endif //BMI_H diff --git a/test/test_bmi.c b/test/test_bmi.c index e0530fc..6dfa7fc 100644 --- a/test/test_bmi.c +++ b/test/test_bmi.c @@ -19,4 +19,10 @@ float expected = 25; TEST_ASSERT_EQUAL(expected, result); } +void test_ausgabe_ergebnis(void) +{ +const char *result = retResult(25); +char expected[] = "Normalgewicht"; +TEST_ASSERT_EQUAL_STRING(expected, result); +} #endif