mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 18:21:39 +01:00
This allows a test case to have a poll-based event loop with exact control of the sequence of operations. Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com>
30 lines
535 B
C
30 lines
535 B
C
#ifndef TEST_COMMON_H
|
|
#define TEST_COMMON_H
|
|
|
|
#include "libxl.h"
|
|
|
|
#include <assert.h>
|
|
#include <stdlib.h>
|
|
#include <unistd.h>
|
|
#include <fcntl.h>
|
|
#include <sys/stat.h>
|
|
#include <sys/types.h>
|
|
|
|
void test_common_setup(int level);
|
|
|
|
extern libxl_ctx *ctx;
|
|
|
|
void test_common_get_now(void);
|
|
|
|
extern struct timeval now;
|
|
|
|
void test_common_beforepoll(void);
|
|
void test_common_dopoll(void);
|
|
void test_common_afterpoll(void);
|
|
|
|
extern int poll_nfds, poll_nfds_allocd;
|
|
extern struct pollfd *poll_fds;
|
|
extern int poll_timeout;
|
|
|
|
#endif /*TEST_COMMON_H*/
|