From d252b26bcec8ca245d5b9cfa55c2411937d1aa47 Mon Sep 17 00:00:00 2001 From: Christian Reum Date: Mon, 5 Feb 2024 19:54:50 +0100 Subject: [PATCH] unittest 1: Erster Test compile --- test/test_wwm.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/test/test_wwm.c b/test/test_wwm.c index e69de29..a9ec536 100644 --- a/test/test_wwm.c +++ b/test/test_wwm.c @@ -0,0 +1,29 @@ +// test_wwm.c + +#include "unity.h" +#include "wwm.h" + +void setUp(void) { + // set up any initializations if needed +} + +void tearDown(void) { + // clean up after the test if needed +} + +void test_setGeld_and_wwm(void) { + // Initialize or reset variables if needed + runde = 0; + geld = 0; + frage = 0; + useranswer = 0; + + // Call setGeld and check the initial values + TEST_ASSERT_EQUAL(0, setGeld(0)); + TEST_ASSERT_EQUAL(0, geld); + + + // Call wwm and check if it runs without errors + //wwm(); + +}