[639] in BarnOwl Developers

home help back first fref pref prev next nref lref last post

[D-O-H] r739 - trunk/owl

daemon@ATHENA.MIT.EDU (nelhage@MIT.EDU)
Thu Oct 29 18:08:12 2009

Resent-From: nelhage@mit.edu
Resent-To: barnowl-dev-mtg@charon.mit.edu
To: dirty-owl-hackers@mit.edu
From: nelhage@MIT.EDU
Reply-to: dirty-owl-hackers@MIT.EDU
Date: Sat,  7 Jul 2007 17:43:22 -0400 (EDT)

Author: nelhage
Date: 2007-07-07 17:43:22 -0400 (Sat, 07 Jul 2007)
New Revision: 739

Modified:
   trunk/owl/filter.c
   trunk/owl/obarray.c
Log:
Forgot these in the last commit; Make all the tests output TAP


Modified: trunk/owl/filter.c
===================================================================
--- trunk/owl/filter.c	2007-07-07 21:42:45 UTC (rev 738)
+++ trunk/owl/filter.c	2007-07-07 21:43:22 UTC (rev 739)
@@ -282,19 +282,19 @@
   int ok;
   int failed = 0;
   if(owl_filter_init_fromstring(&f, "test-filter", filt)) {
-    printf("\tFAIL: parse %s\n", filt);
+    printf("not ok can't parse %s\n", filt);
     failed = 1;
     goto out;
   }
   ok = owl_filter_message_match(&f, m);
   if((shouldmatch && !ok) || (!shouldmatch && ok)) {
-    printf("\tFAIL: match %s (got %d, expected %d)\n", filt, ok, shouldmatch);
+    printf("not ok match %s (got %d, expected %d)\n", filt, ok, shouldmatch);
     failed = 1;
   }
  out:
   owl_filter_free(&f);
   if(!failed) {
-    printf("\tok  : %s %s\n", shouldmatch ? "matches" : "doesn't match", filt);
+    printf("ok %s %s\n", shouldmatch ? "matches" : "doesn't match", filt);
   }
   return failed;
 }

Modified: trunk/owl/obarray.c
===================================================================
--- trunk/owl/obarray.c	2007-07-07 21:42:45 UTC (rev 738)
+++ trunk/owl/obarray.c	2007-07-07 21:43:22 UTC (rev 739)
@@ -79,7 +79,7 @@
   owl_obarray oa;
   owl_obarray_init(&oa);
 
-  printf("BEGIN testing owl_obarray\n");
+  printf("# BEGIN testing owl_obarray\n");
 
   p = owl_obarray_insert(&oa, "test");
   FAIL_UNLESS("returned string is equal", p && !strcmp(p, "test"));
@@ -95,7 +95,7 @@
   p = owl_obarray_find(&oa, "nothere");
   FAIL_UNLESS("Didn't find a string that isn't there", p == NULL);
 
-  printf("END testing owl_obarray (%d failures)\n", numfailed);
+  printf("# END testing owl_obarray (%d failures)\n", numfailed);
 
   return numfailed;
 }


home help back first fref pref prev next nref lref last post