]> git.armaanb.net Git - libacheam.git/blobdiff - src/tests.c
Add tests, restructure repo, and add static target
[libacheam.git] / src / tests.c
diff --git a/src/tests.c b/src/tests.c
new file mode 100644 (file)
index 0000000..c7dd2a2
--- /dev/null
@@ -0,0 +1,18 @@
+#include <acheam.h>
+#include <assert.h>
+
+#include <string.h>
+#include <stdio.h>
+
+int
+main(void)
+{
+       // tolowerw()
+       assert(strcmp(tolowerw("eXaMpLe StRiNg"), "example string") == 0);
+
+       // toupperw()
+       assert(strcmp(toupperw("eXaMpLe StRiNg"), "EXAMPLE STRING") == 0);
+
+       printf("All tests passed succesfully!\n");
+       return 0;
+}