Skip to content
Snippets Groups Projects
Commit 6fadedc3dc4e authored by Nick Wellnhofer's avatar Nick Wellnhofer
Browse files

tests: Remove unused leak statistics

parent 216da731f7f2
No related branches found
No related tags found
No related merge requests found
......@@ -152,7 +152,6 @@
static int nb_tests = 0;
static int nb_errors = 0;
static int nb_leaks = 0;
static int
fatalError(void) {
......@@ -794,7 +793,7 @@
static int
runtest(int i) {
int ret = 0, res;
int old_errors, old_tests, old_leaks;
int old_errors, old_tests;
old_errors = nb_errors;
old_tests = nb_tests;
......@@ -798,10 +797,9 @@
old_errors = nb_errors;
old_tests = nb_tests;
old_leaks = nb_leaks;
if ((tests_quiet == 0) && (testDescriptions[i].desc != NULL))
printf("## Running %s\n", testDescriptions[i].desc);
res = launchTests(&testDescriptions[i]);
if (res != 0)
ret++;
if (verbose) {
......@@ -802,9 +800,9 @@
if ((tests_quiet == 0) && (testDescriptions[i].desc != NULL))
printf("## Running %s\n", testDescriptions[i].desc);
res = launchTests(&testDescriptions[i]);
if (res != 0)
ret++;
if (verbose) {
if ((nb_errors == old_errors) && (nb_leaks == old_leaks))
if (nb_errors == old_errors)
printf("Ran %d tests, no errors\n", nb_tests - old_tests);
else
......@@ -809,4 +807,4 @@
printf("Ran %d tests, no errors\n", nb_tests - old_tests);
else
printf("Ran %d tests, %d errors, %d leaks\n",
printf("Ran %d tests, %d errors\n",
nb_tests - old_tests,
......@@ -812,6 +810,5 @@
nb_tests - old_tests,
nb_errors - old_errors,
nb_leaks - old_leaks);
nb_errors - old_errors);
}
return(ret);
}
......@@ -855,9 +852,9 @@
ret += runtest(i);
}
}
if ((nb_errors == 0) && (nb_leaks == 0)) {
if (nb_errors == 0) {
ret = 0;
printf("Total %d tests, no errors\n",
nb_tests);
} else {
ret = 1;
......@@ -859,10 +856,10 @@
ret = 0;
printf("Total %d tests, no errors\n",
nb_tests);
} else {
ret = 1;
printf("Total %d tests, %d errors, %d leaks\n",
nb_tests, nb_errors, nb_leaks);
printf("Total %d tests, %d errors\n",
nb_tests, nb_errors);
}
xmlCleanupParser();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment