chiark / gitweb /
@@@ wip mostly xfail
[mLib] / test / tvec.h
index d18411ca8077c3cad01ae41f5e99da48c721676d..e9e785af91b78983544b3ddffe20dfc5666ed066 100644 (file)
@@ -432,6 +432,7 @@ enum {
   TVOUT_LOSE,                          /* test failed */
   TVOUT_SKIP,                          /* test skipped */
   TVOUT_WIN,                           /* test passed */
+  TVOUT_XFAIL,                         /* test passed, but shouldn't have */
   TVOUT_LIMIT                          /* (number of possible outcomes) */
 };
 
@@ -439,12 +440,13 @@ struct tvec_state {
   /* The primary state structure for the test vector machinery. */
 
   unsigned f;                          /* flags */
-#define TVSF_SKIP 1u                   /*   skip this test group */
-#define TVSF_OPEN 2u                   /*   test is open */
-#define TVSF_ACTIVE 4u                 /*   test is active */
-#define TVSF_ERROR 8u                  /*   an error occurred */
-#define TVSF_OUTMASK 0xf0              /*   test outcome (@TVOUT_...@) */
+#define TVSF_SKIP 0x0001u              /*   skip this test group */
+#define TVSF_OPEN 0x0002u              /*   test is open */
+#define TVSF_ACTIVE 0x0004u            /*   test is active */
+#define TVSF_ERROR 0x0008u             /*   an error occurred */
+#define TVSF_OUTMASK 0x00f0u           /*   test outcome (@TVOUT_...@) */
 #define TVSF_OUTSHIFT 4                        /*   shift applied to outcome */
+#define TVSF_XFAIL 0x0100u             /*   test expected to fail */
 
   /* Registers.  Available to execution environments. */
   unsigned nrout, nreg;                       /* number of output/total registers */
@@ -652,9 +654,9 @@ extern int tvec_read(struct tvec_state */*tv*/,
 /*----- Command-line interface --------------------------------------------*/
 
 extern const struct tvec_config tvec_adhocconfig;
-/* A special @struct tvec_config@ to use for programs which perform ad-hoc
- * testing.
- */
+  /* A special @struct tvec_config@ to use for programs which perform ad-hoc
  * testing.
  */
 
 /* --- @tvec_parseargs@ --- *
  *
@@ -1815,7 +1817,8 @@ TVEC_MISCSLOTS(DEFINFO)
 #undef DEFINFO
 
 /* Standard enumerations. */
-const struct tvec_ienuminfo tvenum_bool;
+extern const struct tvec_ienuminfo tvenum_bool;
+extern const struct tvec_ienuminfo tvenum_cmp;
 
 /* --- @tvec_claimeq_tenum@, @TVEC_CLAIMEQ_TENUM@ --- *
  *