summaryrefslogtreecommitdiff
path: root/tests/unit_tests.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit_tests.c')
-rw-r--r--tests/unit_tests.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/unit_tests.c b/tests/unit_tests.c
new file mode 100644
index 0000000..45ad926
--- /dev/null
+++ b/tests/unit_tests.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <stdbool.h>
+#include <setjmp.h>
+#include <cmocka.h>
+
+/* A test case that does nothing and succeeds. */
+static void bool_always_success(void **state) {
+ (void) state; /* unused */
+
+ bool this_is_true = true;
+
+ assert_true(this_is_true);
+}
+
+int main(void) {
+ const struct CMUnitTest tests[] = {
+ cmocka_unit_test(bool_always_success),
+ };
+
+ return cmocka_run_group_tests(tests, NULL, NULL);
+}