ReactOS  0.4.15-dev-1397-g19779b3
enum_jobs.c File Reference
#include <stdio.h>
#include "wine/test.h"
#include "bits.h"
Include dependency graph for enum_jobs.c:

Go to the source code of this file.

Macros

#define COBJMACROS
 

Typedefs

typedef void(* test_t) (void)
 

Functions

static BOOL setup (void)
 
static void teardown (void)
 
static void test_GetCount (void)
 
static void test_Next_walkListNull (void)
 
static void test_Next_walkList_1 (void)
 
static void test_Next_walkList_2 (void)
 
static void test_Next_errors (void)
 
static void test_Skip_walkList (void)
 
static void test_Skip_offEnd (void)
 
static void test_Reset (void)
 
 START_TEST (enum_jobs)
 

Variables

static const WCHAR test_displayNameA [] = {'T','e','s','t','A', 0}
 
static const WCHAR test_displayNameB [] = {'T','e','s','t','B', 0}
 
static IBackgroundCopyManagertest_manager
 
static IBackgroundCopyJobtest_jobA
 
static IBackgroundCopyJobtest_jobB
 
static ULONG test_jobCountB
 
static IEnumBackgroundCopyJobstest_enumJobsA
 
static IEnumBackgroundCopyJobstest_enumJobsB
 
static GUID test_jobIdA
 
static GUID test_jobIdB
 

Macro Definition Documentation

◆ COBJMACROS

#define COBJMACROS

Definition at line 23 of file enum_jobs.c.

Typedef Documentation

◆ test_t

typedef void(* test_t) (void)

Definition at line 246 of file enum_jobs.c.

Function Documentation

◆ setup()

static BOOL setup ( void  )
static

Definition at line 41 of file enum_jobs.c.

42 {
43  HRESULT hres;
44 
46  test_jobA = NULL;
47  test_jobB = NULL;
48  memset(&test_jobIdA, 0, sizeof test_jobIdA);
49  memset(&test_jobIdB, 0, sizeof test_jobIdB);
50 
51  hres = CoCreateInstance(&CLSID_BackgroundCopyManager, NULL,
52  CLSCTX_LOCAL_SERVER, &IID_IBackgroundCopyManager,
53  (void **) &test_manager);
54  if(hres != S_OK)
55  return FALSE;
56 
57  hres = IBackgroundCopyManager_CreateJob(test_manager, test_displayNameA,
58  BG_JOB_TYPE_DOWNLOAD, &test_jobIdA,
59  &test_jobA);
60  if(hres != S_OK)
61  return FALSE;
62 
63  hres = IBackgroundCopyManager_EnumJobs(test_manager, 0, &test_enumJobsA);
64  if(hres != S_OK)
65  return FALSE;
66 
67  hres = IBackgroundCopyManager_CreateJob(test_manager, test_displayNameB,
68  BG_JOB_TYPE_DOWNLOAD, &test_jobIdB,
69  &test_jobB);
70  if(hres != S_OK)
71  return FALSE;
72 
73  hres = IBackgroundCopyManager_EnumJobs(test_manager, 0, &test_enumJobsB);
74  if(hres != S_OK)
75  return FALSE;
76 
77  hres = IEnumBackgroundCopyJobs_GetCount(test_enumJobsB, &test_jobCountB);
78  if (hres != S_OK)
79  return FALSE;
80 
81  return TRUE;
82 }
#define TRUE
Definition: types.h:120
static const WCHAR test_displayNameA[]
Definition: enum_jobs.c:29
static IBackgroundCopyJob * test_jobB
Definition: enum_jobs.c:33
static const WCHAR test_displayNameB[]
Definition: enum_jobs.c:30
#define FALSE
Definition: types.h:117
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
static IEnumBackgroundCopyJobs * test_enumJobsA
Definition: enum_jobs.c:35
HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance(REFCLSID rclsid, LPUNKNOWN pUnkOuter, DWORD dwClsContext, REFIID iid, LPVOID *ppv)
Definition: compobj.c:3325
#define S_OK
Definition: intsafe.h:51
#define NULL
Definition: types.h:112
static GUID test_jobIdA
Definition: enum_jobs.c:37
static GUID test_jobIdB
Definition: enum_jobs.c:38
static IBackgroundCopyJob * test_jobA
Definition: enum_jobs.c:32
#define memset(x, y, z)
Definition: compat.h:39

Referenced by START_TEST().

◆ START_TEST()

START_TEST ( enum_jobs  )

Definition at line 248 of file enum_jobs.c.

249 {
250  static const test_t tests[] = {
258  test_Reset,
259  0
260  };
261  const test_t *test;
262  int i;
263 
265  for (test = tests, i = 0; *test; ++test, ++i)
266  {
267  /* Keep state separate between tests */
268  if (!setup())
269  {
270  teardown();
271  ok(0, "tests:%d: Unable to setup test\n", i);
272  break;
273  }
274  (*test)();
275  teardown();
276  }
277  CoUninitialize();
278 }
static void test_Next_walkList_2(void)
Definition: enum_jobs.c:169
static BOOL setup(void)
Definition: enum_jobs.c:41
static struct test_info tests[]
static void test_Skip_offEnd(void)
Definition: enum_jobs.c:223
#define test
Definition: rosglue.h:37
static void test_Next_walkListNull(void)
Definition: enum_jobs.c:124
static void test_GetCount(void)
Definition: enum_jobs.c:109
static void test_Next_errors(void)
Definition: enum_jobs.c:196
static void teardown(void)
Definition: enum_jobs.c:85
void(* test_t)(void)
Definition: enum_jobs.c:246
static void test_Next_walkList_1(void)
Definition: enum_jobs.c:144
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
void WINAPI DECLSPEC_HOTPATCH CoUninitialize(void)
Definition: compobj.c:2067
#define ok(value,...)
Definition: atltest.h:57
static void test_Reset(void)
Definition: enum_jobs.c:232
#define NULL
Definition: types.h:112
HRESULT WINAPI CoInitialize(LPVOID lpReserved)
Definition: compobj.c:1964
static void test_Skip_walkList(void)
Definition: enum_jobs.c:207

◆ teardown()

static void teardown ( void  )
static

Definition at line 85 of file enum_jobs.c.

86 {
87  if (test_enumJobsB)
88  IEnumBackgroundCopyJobs_Release(test_enumJobsB);
90  if (test_jobB)
91  IBackgroundCopyJob_Release(test_jobB);
92  test_jobB = NULL;
93  if (test_enumJobsA)
94  IEnumBackgroundCopyJobs_Release(test_enumJobsA);
96  if (test_jobA)
97  IBackgroundCopyJob_Release(test_jobA);
98  test_jobA = NULL;
99  if (test_manager)
100  IBackgroundCopyManager_Release(test_manager);
101  test_manager = NULL;
102 }
static IBackgroundCopyJob * test_jobB
Definition: enum_jobs.c:33
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
static IEnumBackgroundCopyJobs * test_enumJobsA
Definition: enum_jobs.c:35
#define NULL
Definition: types.h:112
static IBackgroundCopyJob * test_jobA
Definition: enum_jobs.c:32

Referenced by START_TEST().

◆ test_GetCount()

static void test_GetCount ( void  )
static

Definition at line 109 of file enum_jobs.c.

110 {
111  HRESULT hres;
112  ULONG jobCountA, jobCountB;
113 
114  hres = IEnumBackgroundCopyJobs_GetCount(test_enumJobsA, &jobCountA);
115  ok(hres == S_OK, "GetCount failed: %08x\n", hres);
116 
117  hres = IEnumBackgroundCopyJobs_GetCount(test_enumJobsB, &jobCountB);
118  ok(hres == S_OK, "GetCount failed: %08x\n", hres);
119 
120  ok(jobCountB == jobCountA + 1, "Got incorrect count\n");
121 }
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static IEnumBackgroundCopyJobs * test_enumJobsA
Definition: enum_jobs.c:35
#define S_OK
Definition: intsafe.h:51
#define ok(value,...)
Definition: atltest.h:57
unsigned int ULONG
Definition: retypes.h:1

Referenced by START_TEST().

◆ test_Next_errors()

static void test_Next_errors ( void  )
static

Definition at line 196 of file enum_jobs.c.

197 {
198  HRESULT hres;
199  IBackgroundCopyJob *jobs[2];
200 
201  /* E_INVALIDARG: pceltFetched can ONLY be NULL if celt is 1 */
202  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, 2, jobs, NULL);
203  ok(hres != S_OK, "Invalid call to Next succeeded: %08x\n", hres);
204 }
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
#define S_OK
Definition: intsafe.h:51
#define ok(value,...)
Definition: atltest.h:57
#define NULL
Definition: types.h:112

Referenced by START_TEST().

◆ test_Next_walkList_1()

static void test_Next_walkList_1 ( void  )
static

Definition at line 144 of file enum_jobs.c.

145 {
146  HRESULT hres;
148  ULONG fetched;
149  ULONG i;
150 
151  /* Fetch the available jobs */
152  for (i = 0; i < test_jobCountB; i++)
153  {
154  fetched = 0;
155  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, 1, &job, &fetched);
156  ok(hres == S_OK, "Next failed: %08x\n", hres);
157  ok(fetched == 1, "Next returned the incorrect number of jobs: %08x\n", hres);
158  IBackgroundCopyJob_Release(job);
159  }
160 
161  /* Attempt to fetch one more than the number of available jobs */
162  fetched = 0;
163  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, 1, &job, &fetched);
164  ok(hres == S_FALSE, "Next off end of available jobs failed: %08x\n", hres);
165  ok(fetched == 0, "Next returned the incorrect number of jobs: %08x\n", hres);
166 }
static HANDLE job
Definition: process.c:77
#define S_FALSE
Definition: winerror.h:2357
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define S_OK
Definition: intsafe.h:51
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ok(value,...)
Definition: atltest.h:57
unsigned int ULONG
Definition: retypes.h:1

Referenced by START_TEST().

◆ test_Next_walkList_2()

static void test_Next_walkList_2 ( void  )
static

Definition at line 169 of file enum_jobs.c.

170 {
171  HRESULT hres;
172  IBackgroundCopyJob **jobs;
173  ULONG fetched;
174  ULONG i;
175 
176  jobs = HeapAlloc(GetProcessHeap(), 0, test_jobCountB * sizeof *jobs);
177  for (i = 0; i < test_jobCountB; i++)
178  jobs[i] = NULL;
179 
180  fetched = 0;
181  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, test_jobCountB, jobs, &fetched);
182  ok(hres == S_OK, "Next failed: %08x\n", hres);
183  ok(fetched == test_jobCountB, "Next returned the incorrect number of jobs: %08x\n", hres);
184 
185  for (i = 0; i < test_jobCountB; i++)
186  {
187  ok(jobs[i] != NULL, "Next returned NULL\n");
188  if (jobs[i])
189  IBackgroundCopyJob_Release(jobs[i]);
190  }
191 
192  HeapFree(GetProcessHeap(), 0, jobs);
193 }
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
#define GetProcessHeap()
Definition: compat.h:595
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define S_OK
Definition: intsafe.h:51
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ok(value,...)
Definition: atltest.h:57
#define NULL
Definition: types.h:112
unsigned int ULONG
Definition: retypes.h:1
#define HeapFree(x, y, z)
Definition: compat.h:594

Referenced by START_TEST().

◆ test_Next_walkListNull()

static void test_Next_walkListNull ( void  )
static

Definition at line 124 of file enum_jobs.c.

125 {
126  HRESULT hres;
128  ULONG i;
129 
130  /* Fetch the available jobs */
131  for (i = 0; i < test_jobCountB; i++)
132  {
133  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, 1, &job, NULL);
134  ok(hres == S_OK, "Next failed: %08x\n", hres);
135  IBackgroundCopyJob_Release(job);
136  }
137 
138  /* Attempt to fetch one more than the number of available jobs */
139  hres = IEnumBackgroundCopyJobs_Next(test_enumJobsB, 1, &job, NULL);
140  ok(hres == S_FALSE, "Next off end of available jobs failed: %08x\n", hres);
141 }
static HANDLE job
Definition: process.c:77
#define S_FALSE
Definition: winerror.h:2357
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define S_OK
Definition: intsafe.h:51
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ok(value,...)
Definition: atltest.h:57
#define NULL
Definition: types.h:112
unsigned int ULONG
Definition: retypes.h:1

Referenced by START_TEST().

◆ test_Reset()

static void test_Reset ( void  )
static

Definition at line 232 of file enum_jobs.c.

233 {
234  HRESULT hres;
235 
236  hres = IEnumBackgroundCopyJobs_Skip(test_enumJobsB, test_jobCountB);
237  ok(hres == S_OK, "Skip failed: %08x\n", hres);
238 
239  hres = IEnumBackgroundCopyJobs_Reset(test_enumJobsB);
240  ok(hres == S_OK, "Reset failed: %08x\n", hres);
241 
242  hres = IEnumBackgroundCopyJobs_Skip(test_enumJobsB, test_jobCountB);
243  ok(hres == S_OK, "Reset failed: %08x\n", hres);
244 }
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define S_OK
Definition: intsafe.h:51
#define ok(value,...)
Definition: atltest.h:57

Referenced by START_TEST().

◆ test_Skip_offEnd()

static void test_Skip_offEnd ( void  )
static

Definition at line 223 of file enum_jobs.c.

224 {
225  HRESULT hres;
226 
227  hres = IEnumBackgroundCopyJobs_Skip(test_enumJobsB, test_jobCountB + 1);
228  ok(hres == S_FALSE, "Skip expected end of list: %08x\n", hres);
229 }
#define S_FALSE
Definition: winerror.h:2357
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define ok(value,...)
Definition: atltest.h:57

Referenced by START_TEST().

◆ test_Skip_walkList()

static void test_Skip_walkList ( void  )
static

Definition at line 207 of file enum_jobs.c.

208 {
209  HRESULT hres;
210  ULONG i;
211 
212  for (i = 0; i < test_jobCountB; i++)
213  {
214  hres = IEnumBackgroundCopyJobs_Skip(test_enumJobsB, 1);
215  ok(hres == S_OK, "Skip failed: %08x\n", hres);
216  }
217 
218  hres = IEnumBackgroundCopyJobs_Skip(test_enumJobsB, 1);
219  ok(hres == S_FALSE, "Skip expected end of list: %08x\n", hres);
220 }
#define S_FALSE
Definition: winerror.h:2357
static IEnumBackgroundCopyJobs * test_enumJobsB
Definition: enum_jobs.c:36
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:79
static ULONG test_jobCountB
Definition: enum_jobs.c:34
#define S_OK
Definition: intsafe.h:51
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ok(value,...)
Definition: atltest.h:57
unsigned int ULONG
Definition: retypes.h:1

Referenced by START_TEST().

Variable Documentation

◆ test_displayNameA

const WCHAR test_displayNameA[] = {'T','e','s','t','A', 0}
static

Definition at line 29 of file enum_jobs.c.

Referenced by setup().

◆ test_displayNameB

const WCHAR test_displayNameB[] = {'T','e','s','t','B', 0}
static

Definition at line 30 of file enum_jobs.c.

Referenced by setup().

◆ test_enumJobsA

IEnumBackgroundCopyJobs* test_enumJobsA
static

Definition at line 35 of file enum_jobs.c.

Referenced by setup(), teardown(), and test_GetCount().

◆ test_enumJobsB

◆ test_jobA

IBackgroundCopyJob* test_jobA
static

Definition at line 32 of file enum_jobs.c.

Referenced by setup(), and teardown().

◆ test_jobB

IBackgroundCopyJob* test_jobB
static

Definition at line 33 of file enum_jobs.c.

Referenced by setup(), and teardown().

◆ test_jobCountB

◆ test_jobIdA

GUID test_jobIdA
static

Definition at line 37 of file enum_jobs.c.

Referenced by setup().

◆ test_jobIdB

GUID test_jobIdB
static

Definition at line 38 of file enum_jobs.c.

Referenced by setup().

◆ test_manager

Definition at line 31 of file enum_jobs.c.