#include <debug.h>#include <stdbool.h>#include <stddef.h>#include <syscall.h>Go to the source code of this file.
Defines | |
| #define | CHECK(SUCCESS,...) |
Functions | |
| void | msg (const char *,...) PRINTF_FORMAT(1 |
| void void | fail (const char *,...) PRINTF_FORMAT(1 |
| void | shuffle (void *, size_t cnt, size_t size) |
| void | exec_children (const char *child_name, pid_t pids[], size_t child_cnt) |
| void | wait_children (pid_t pids[], size_t child_cnt) |
| void | check_file_handle (int fd, const char *file_name, const void *buf_, size_t filesize) |
| void | check_file (const char *file_name, const void *buf, size_t filesize) |
| void | compare_bytes (const void *read_data, const void *expected_data, size_t size, size_t ofs, const char *file_name) |
Variables | |
| const char * | test_name |
| bool | quiet |
| void void | NO_RETURN |
| #define CHECK | ( | SUCCESS, | |||
| ... | ) |
Value:
Definition at line 30 of file lib.h.
Referenced by check_file(), do_mkdir(), do_remove(), do_touch(), exec_children(), main(), make_tree(), remove_tree(), seq_test(), sort_chunks(), test_main(), try_write(), wait_children(), and wrap_open().
| void check_file | ( | const char * | file_name, | |
| const void * | buf, | |||
| size_t | filesize | |||
| ) |
Definition at line 152 of file lib.c.
References CHECK, check_file_handle(), close(), msg(), and open().
Referenced by seq_test(), and test_main().
| void check_file_handle | ( | int | fd, | |
| const char * | file_name, | |||
| const void * | buf_, | |||
| size_t | filesize | |||
| ) |
Definition at line 109 of file lib.c.
References block_size(), buf, compare_bytes(), fail(), filesize(), msg(), and read().
Referenced by check_file(), and test_main().
| void compare_bytes | ( | const void * | read_data, | |
| const void * | expected_data, | |||
| size_t | size, | |||
| size_t | ofs, | |||
| const char * | file_name | |||
| ) |
Definition at line 164 of file lib.c.
References fail(), hex_dump(), memcmp(), msg(), and quiet.
Referenced by check_file_handle(), main(), and test_main().
Definition at line 81 of file lib.c.
References CHECK, exec(), PID_ERROR, and snprintf().
Referenced by test_main().
| bool quiet |
Definition at line 10 of file lib.c.
Referenced by compare_bytes(), main(), make_tree(), msg(), remove_tree(), sort_chunks(), test_main(), and try_write().
| const char* test_name |
Definition at line 14 of file child-syn-read.c.
Referenced by consume_some_resources(), fail(), main(), msg(), pass(), run_test(), spawn_child(), and vmsg().
1.5.6