X-Git-Url: http://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Fntdb%2Ftest%2Ffailtest_helper.h;fp=ccan%2Fntdb%2Ftest%2Ffailtest_helper.h;h=8d1c3745158fbcaeb0811ee5cf171095f9ec6e03;hp=0000000000000000000000000000000000000000;hb=d69ef83fcc2434ddaced1831184fb761ae6f09d3;hpb=ed95d8600afe1564ffd1783ae9ea0ef6324904dc diff --git a/ccan/ntdb/test/failtest_helper.h b/ccan/ntdb/test/failtest_helper.h new file mode 100644 index 00000000..8d1c3745 --- /dev/null +++ b/ccan/ntdb/test/failtest_helper.h @@ -0,0 +1,18 @@ +#ifndef NTDB_TEST_FAILTEST_HELPER_H +#define NTDB_TEST_FAILTEST_HELPER_H +#include +#include + +/* FIXME: Check these! */ +#define URANDOM_OPEN "open.c", 62, FAILTEST_OPEN +#define URANDOM_READ "open.c", 42, FAILTEST_READ + +bool exit_check_log(struct tlist_calls *history); +bool failmatch(const struct failtest_call *call, + const char *file, int line, enum failtest_call_type type); +enum failtest_result block_repeat_failures(struct tlist_calls *history); + +/* Set this to suppress failure. */ +extern bool failtest_suppress; + +#endif /* NTDB_TEST_LOGGING_H */