From a768d564635839fef9bff71266385a9792ab2de8 Mon Sep 17 00:00:00 2001 From: fdai7514 Date: Wed, 8 Feb 2023 17:46:37 +0100 Subject: [PATCH] implement unittest for requestLoan.c --- build-project.sh | 1 + tests/test_requestLoan.c | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/build-project.sh b/build-project.sh index a2ee9d4..2321ef5 100755 --- a/build-project.sh +++ b/build-project.sh @@ -1,4 +1,5 @@ clear +ceedling test:all cd src/ gcc main.c -o main ./main diff --git a/tests/test_requestLoan.c b/tests/test_requestLoan.c index 0fcabf3..9dd5e66 100644 --- a/tests/test_requestLoan.c +++ b/tests/test_requestLoan.c @@ -2,7 +2,7 @@ #include "unity.h" -#include "requestLoan.h" +#include "requestLoan.c" void setUp(void) { @@ -12,9 +12,11 @@ void tearDown(void) { } -void test_requestLoan_NeedToImplement(void) +void test_requestLoan(void) { - TEST_IGNORE_MESSAGE("Need to Implement requestLoan"); + int e; + e = allow(); + TEST_ASSERT_EQUAL_INT(1, e); } #endif // TEST