2 * SPDX-License-Identifier: BSD-2-Clause
4 * Copyright (C) 2004 Nik Clayton
5 * Copyright (C) 2017 Jérémie Galarneau
12 # define ok(e, ...) ((e) ? \
13 _gen_result(1, __func__, __FILE__, __LINE__, \
15 _gen_result(0, __func__, __FILE__, __LINE__, \
18 # define ok1(e) ((e) ? \
19 _gen_result(1, __func__, __FILE__, __LINE__, "%s", #e) : \
20 _gen_result(0, __func__, __FILE__, __LINE__, "%s", #e))
22 # define pass(...) ok(1, __VA_ARGS__)
23 # define fail(...) ok(0, __VA_ARGS__)
25 # define skip_start(test, n, ...) \
28 skip(n, __VA_ARGS__); \
32 #define skip_end() } while(0);
34 #ifdef __MINGW_PRINTF_FORMAT
35 # define TAP_PRINTF_FORMAT __MINGW_PRINTF_FORMAT
37 # define TAP_PRINTF_FORMAT printf
40 __attribute__((format(TAP_PRINTF_FORMAT
, 5, 6)))
41 unsigned int _gen_result(int, const char *, const char *, unsigned int, const char *, ...);
43 int plan_no_plan(void);
44 __attribute__((__noreturn__
))
45 int plan_skip_all(const char *);
46 int plan_tests(unsigned int);
48 __attribute__((format(TAP_PRINTF_FORMAT
, 1, 2)))
49 unsigned int diag(const char *, ...);
50 void diag_multiline(const char *);
52 __attribute__((format(TAP_PRINTF_FORMAT
, 2, 3)))
53 int skip(unsigned int, const char *, ...);
55 __attribute__((format(TAP_PRINTF_FORMAT
, 1, 2)))
56 void todo_start(const char *, ...);
59 int exit_status(void);
61 void tap_disable(void);
63 unsigned int rdiag_start(void);
64 __attribute__((format(TAP_PRINTF_FORMAT
, 1, 2)))
65 unsigned int rdiag(const char *fmt
, ...);
66 unsigned int rdiag_end(void);
This page took 0.04362 seconds and 4 git commands to generate.