From 11dfa2145f4f2e9ac4af1bb84a7ec8b71cd6492f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sun, 21 Nov 2021 20:13:08 +0100 Subject: [PATCH] test: unlink config file in teardown --- tests/test-foot.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test-foot.c b/tests/test-foot.c index 1e79233c..088244ea 100644 --- a/tests/test-foot.c +++ b/tests/test-foot.c @@ -49,7 +49,9 @@ static void conf_file_teardown(void) { if (conf_file.fd >= 0) - close(conf_file.fd); + ck_assert_int_eq(close(conf_file.fd), 0); + if (conf_file.path != NULL) + ck_assert_int_eq(unlink(conf_file.path), 0); } }