This source file contains the implementation of network interaction functions related to the UDP network fake for tftpfs testing.
More...
|
|
void | _Tftp_Add_interaction_socket (int domain, int type, int protocol, int result) |
|
void | _Tftp_Add_interaction_close (int fd, int result) |
|
void | _Tftp_Add_interaction_bind (int fd, int family, int result) |
|
void | _Tftp_Add_interaction_send_rrq (int fd, const char *filename, uint16_t dest_port, const char *dest_addr_str, uint16_t block_size, uint16_t window_size, bool result) |
|
void | _Tftp_Add_interaction_send_wrq (int fd, const char *filename, uint16_t dest_port, const char *dest_addr_str, uint16_t block_size, uint16_t window_size, bool result) |
|
void | _Tftp_Add_interaction_send_ack (int fd, uint16_t block_num, uint16_t dest_port, const char *dest_addr_str, bool result) |
|
void | _Tftp_Add_interaction_send_data (int fd, uint16_t block_num, size_t start, size_t len, uint8_t(*get_data)(size_t pos), uint16_t dest_port, const char *dest_addr_str, bool result) |
|
void | _Tftp_Add_interaction_send_error (int fd, uint16_t error_code, uint16_t dest_port, const char *dest_addr_str, bool result) |
|
void | _Tftp_Add_interaction_recv_data (int fd, uint32_t timeout_ms, uint16_t src_port, const char *src_addr_str, uint16_t block_num, size_t start, size_t len, uint8_t(*get_data)(size_t pos), bool result) |
|
void | _Tftp_Add_interaction_recv_ack (int fd, uint32_t timeout_ms, uint16_t src_port, const char *src_addr_str, uint16_t block_num, bool result) |
|
void | _Tftp_Add_interaction_recv_oack (int fd, uint32_t timeout_ms, uint16_t src_port, const char *src_addr_str, const char *options, size_t options_size, bool result) |
|
void | _Tftp_Add_interaction_recv_error (int fd, uint32_t timeout_ms, uint16_t src_port, const char *src_addr_str, uint16_t error_code, const char *err_msg, bool result) |
|
void | _Tftp_Add_interaction_recv_raw (int fd, uint32_t timeout_ms, uint16_t src_port, const char *src_addr_str, size_t len, const uint8_t *bytes, bool result) |
|
void | _Tftp_Add_interaction_recv_nothing (int fd, uint32_t timeout_ms) |
This source file contains the implementation of network interaction functions related to the UDP network fake for tftpfs testing.
The UDP Network Fake requires interactions between TFTP client and test (which emulates a TFTP server). The idea is that each test defines a sequence of interactions. In a successful test run all interactions must be carried out one-by-one till the last interaction is reached.
Interactions appear when the TFTP client calls functions like sendto(), recvfrom(), or socket(). Here functions are defined which
- handle such interactions and
- permit the tests to easily defined the sequence of interactions.