testprogs: test each printer, do not abort after first failure.
authorGünther Deschner <gd@samba.org>
Mon, 11 Jan 2010 11:37:45 +0000 (12:37 +0100)
committerGünther Deschner <gd@samba.org>
Mon, 11 Jan 2010 11:43:07 +0000 (12:43 +0100)
Guenther

testprogs/win32/spoolss/spoolss.c

index 718fb379eaa74ea0f79aa595144ecaa560be844c..16f45b02f34e8893e31090b9ac02b0190180a468 100644 (file)
@@ -599,6 +599,7 @@ static BOOL test_EachPrinter(struct torture_context *tctx,
        DWORD i;
        DWORD flags = PRINTER_ENUM_NAME;
        PPRINTER_INFO_1 buffer = NULL;
+       BOOL ret = TRUE;
 
        torture_comment(tctx, "Testing EnumPrinters level %d", 1);
 
@@ -619,13 +620,12 @@ static BOOL test_EachPrinter(struct torture_context *tctx,
        }
 
        for (i=0; i < returned; i++) {
-               torture_assert(tctx, test_OnePrinter(tctx, buffer[i].pName, architecture),
-                       "failed to test one printer");
+               ret &= test_OnePrinter(tctx, buffer[i].pName, architecture);
        }
 
        free(buffer);
 
-       return TRUE;
+       return ret;
 }
 
 /****************************************************************************