test: Add NDEBUG sanity check

Hopefully stops people tripping over themselves if NDEBUG gets defined.

Change-Id: Iafb81d01f6451619f49a5030e5154c8f30ffebdb
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
diff --git a/Makefile.am b/Makefile.am
index 050de35..dea382f 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -14,3 +14,9 @@
 AM_LIBS = $(CODE_COVERAGE_LIBS)
 AM_CPPFLAGS = $(CODE_COVERAGE_CPPFLAGS)
 AM_CFLAGS = $(CODE_COVERAGE_CFLAGS)
+
+test_sanity_SOURCES = test/sanity.c
+
+check_PROGRAMS = test/sanity
+
+TESTS = $(check_PROGRAMS)
diff --git a/test/sanity.c b/test/sanity.c
new file mode 100644
index 0000000..b4989f8
--- /dev/null
+++ b/test/sanity.c
@@ -0,0 +1,8 @@
+int main(void)
+{
+#ifdef NDEBUG
+	return 1;
+#else
+	return 0;
+#endif
+}