ReactOS 0.4.15-dev-8222-g9164419
She.cpp File Reference
#include "shelltest.h"
#include <undocshell.h>
Include dependency graph for She.cpp:

Go to the source code of this file.

Typedefs

typedef LPSTR(WINAPIFN_SheRemoveQuotesA) (LPSTR psz)
 
typedef LPWSTR(WINAPIFN_SheRemoveQuotesW) (LPWSTR psz)
 

Functions

static void test_SheRemoveQuotesA (void)
 
static void test_SheRemoveQuotesW (void)
 
 START_TEST (She)
 

Variables

static FN_SheRemoveQuotesA pSheRemoveQuotesA = NULL
 
static FN_SheRemoveQuotesW pSheRemoveQuotesW = NULL
 

Typedef Documentation

◆ FN_SheRemoveQuotesA

typedef LPSTR(WINAPI * FN_SheRemoveQuotesA) (LPSTR psz)

Definition at line 11 of file She.cpp.

◆ FN_SheRemoveQuotesW

typedef LPWSTR(WINAPI * FN_SheRemoveQuotesW) (LPWSTR psz)

Definition at line 12 of file She.cpp.

Function Documentation

◆ START_TEST()

START_TEST ( She  )

Definition at line 73 of file She.cpp.

74{
78
80 {
81 skip("SheRemoveQuotes not found");
82 return;
83 }
84
87}
static void test_SheRemoveQuotesA(void)
Definition: She.cpp:17
static FN_SheRemoveQuotesA pSheRemoveQuotesA
Definition: She.cpp:14
LPWSTR(WINAPI * FN_SheRemoveQuotesW)(LPWSTR psz)
Definition: She.cpp:12
LPSTR(WINAPI * FN_SheRemoveQuotesA)(LPSTR psz)
Definition: She.cpp:11
static void test_SheRemoveQuotesW(void)
Definition: She.cpp:45
static FN_SheRemoveQuotesW pSheRemoveQuotesW
Definition: She.cpp:15
#define skip(...)
Definition: atltest.h:64
#define GetProcAddress(x, y)
Definition: compat.h:753
HMODULE WINAPI GetModuleHandleW(LPCWSTR lpModuleName)
Definition: loader.c:838
static HMODULE hShell32
Definition: string.c:34
#define L(x)
Definition: ntvdm.h:50

◆ test_SheRemoveQuotesA()

static void test_SheRemoveQuotesA ( void  )
static

Definition at line 17 of file She.cpp.

18{
19 CHAR sz0[] = "A\"Test\"";
20 CHAR sz1[] = "\"Test\"";
21 CHAR sz2[] = "\"Test\"123";
22
25 {
27 }
29 {
31 }
34
35 ok_ptr(pSheRemoveQuotesA(sz0), sz0);
36 ok_str(sz0, "A\"Test\"");
37
38 ok_ptr(pSheRemoveQuotesA(sz1), sz1);
39 ok_str(sz1, "Test");
40
41 ok_ptr(pSheRemoveQuotesA(sz2), sz2);
42 ok_str(sz2, "Test");
43}
BOOL bGotException
#define ok_str(x, y)
Definition: atltest.h:127
#define ok_int(expression, result)
Definition: atltest.h:134
#define ok_ptr(expression, result)
Definition: atltest.h:108
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
#define _SEH2_END
Definition: filesup.c:22
#define _SEH2_TRY
Definition: filesup.c:19
unsigned int BOOL
Definition: ntddk_ex.h:94
#define EXCEPTION_EXECUTE_HANDLER
Definition: excpt.h:85
#define _SEH2_EXCEPT(...)
Definition: pseh2_64.h:66
char CHAR
Definition: xmlstorage.h:175

Referenced by START_TEST().

◆ test_SheRemoveQuotesW()

static void test_SheRemoveQuotesW ( void  )
static

Definition at line 45 of file She.cpp.

46{
47 WCHAR sz0[] = L"A\"Test\"";
48 WCHAR sz1[] = L"\"Test\"";
49 WCHAR sz2[] = L"\"Test\"123";
50
53 {
55 }
57 {
59 }
62
63 ok_ptr(pSheRemoveQuotesW(sz0), sz0);
64 ok_wstr(sz0, L"A\"Test\"");
65
66 ok_ptr(pSheRemoveQuotesW(sz1), sz1);
67 ok_wstr(sz1, L"Test");
68
69 ok_ptr(pSheRemoveQuotesW(sz2), sz2);
70 ok_wstr(sz2, L"Test");
71}
#define ok_wstr(x, y)
Definition: atltest.h:130
__wchar_t WCHAR
Definition: xmlstorage.h:180

Referenced by START_TEST().

Variable Documentation

◆ pSheRemoveQuotesA

FN_SheRemoveQuotesA pSheRemoveQuotesA = NULL
static

Definition at line 14 of file She.cpp.

Referenced by START_TEST(), and test_SheRemoveQuotesA().

◆ pSheRemoveQuotesW

FN_SheRemoveQuotesW pSheRemoveQuotesW = NULL
static

Definition at line 15 of file She.cpp.

Referenced by START_TEST(), and test_SheRemoveQuotesW().