#include <apitest.h>
#include <ws2tcpip.h>
#include <iphlpapi.h>
#include <icmpapi.h>
Go to the source code of this file.
◆ START_TEST()
Definition at line 134 of file icmp.c.
135{
140}
static void test_Icmp6CreateFile(void)
static void test_IcmpSendEcho(void)
static void test_IcmpCloseHandle(void)
static void test_IcmpCreateFile(void)
◆ test_Icmp6CreateFile()
static void test_Icmp6CreateFile |
( |
void |
| ) |
|
|
static |
Definition at line 29 of file icmp.c.
30{
32
35
37 {
38
39 skip(
"IPv6 is not available.\n");
40 return;
41 }
42
44
47}
#define INVALID_HANDLE_VALUE
BOOL WINAPI IcmpCloseHandle(_In_ HANDLE IcmpHandle)
HANDLE WINAPI Icmp6CreateFile(void)
#define ERROR_FILE_NOT_FOUND
DWORD WINAPI GetLastError(void)
Referenced by START_TEST().
◆ test_IcmpCloseHandle()
static void test_IcmpCloseHandle |
( |
void |
| ) |
|
|
static |
Definition at line 51 of file icmp.c.
52{
56
60 {
62 ok(bRet,
"IcmpCloseHandle failed unexpectedly: %lu\n",
GetLastError());
63 }
64
68 {
70 ok(bRet,
"IcmpCloseHandle failed unexpectedly: %lu\n",
GetLastError());
71 }
72
76 ok(!bRet,
"IcmpCloseHandle succeeded unexpectedly\n");
79 "Unexpected last error (0x%lX)\n", LastError);
80
84 ok(!bRet,
"IcmpCloseHandle succeeded unexpectedly\n");
87 "Unexpected last error (0x%lX)\n", LastError);
88}
#define ERROR_INVALID_PARAMETER
#define ERROR_INVALID_HANDLE
HANDLE WINAPI IcmpCreateFile(void)
Referenced by START_TEST().
◆ test_IcmpCreateFile()
static void test_IcmpCreateFile |
( |
void |
| ) |
|
|
static |
◆ test_IcmpSendEcho()
Definition at line 92 of file icmp.c.
93{
100
104 {
106 return;
107 }
108
109 ipaddr = 0x08080808;
111
116
117 ok(!bRet,
"IcmpSendEcho succeeded unexpectedly\n");
121 "IcmpSendEcho returned unexpected error: %lu\n",
error);
122
127
128 ok(bRet,
"IcmpSendEcho failed unexpectedly: %lu\n",
GetLastError());
129
132}
DWORD WINAPI IcmpSendEcho(_In_ HANDLE IcmpHandle, _In_ IPAddr DestinationAddress, _In_ LPVOID RequestData, _In_ WORD RequestSize, _In_opt_ PIP_OPTION_INFORMATION RequestOptions, _Out_ LPVOID ReplyBuffer, _In_ DWORD ReplySize, _In_ DWORD Timeout)
_Must_inspect_result_ _In_ PFLT_PORT _In_ ULONG _Out_writes_bytes_opt_ ReplyLength PVOID ReplyBuffer
struct icmp_echo_reply ICMP_ECHO_REPLY
#define IP_GENERAL_FAILURE
static BOOL SendData(PINFO pInfo)
Referenced by START_TEST().