tests cleanup

. make common.o link with the tests instead of being
	  #included as common.c
	. fix warnings about missing prototypes by declaring functions
	  static
	. reduces some duplicated code

Change-Id: Ic2a765d7f5886add5863190efec3fdd2d2ea2137
This commit is contained in:
Ben Gras
2013-04-17 22:00:59 +00:00
parent cef94e096e
commit 5977114c42
80 changed files with 364 additions and 327 deletions
+1 -5
View File
@@ -32,11 +32,7 @@ static void GLUE(e, TYPE_FUNC)(int n, const char *s, TYPE result, int base)
/* watch out: don't overwrite the static buffer in make_string */
printf("Subtest %s, error %d, errno=%d, s=\"%s\", base=%d, ", TOSTRING(TYPE_FUNC), n, errno, s, base);
printf("result=%s\n", GLUE(make_string, TYPE_FUNC)(result, base));
if (errct++ > MAX_ERROR)
{
printf("Too many errors; test aborted\n");
exit(1);
}
e(7);
}
static void GLUE(test_string, TYPE_FUNC)(const char *s, TYPE value, int base)