qmgr: Implement IBackgroundCopyJob_GetType with test.
This commit is contained in:
parent
7b297890a7
commit
3f126b4a60
|
@ -133,8 +133,13 @@ static HRESULT WINAPI BITS_IBackgroundCopyJob_GetType(
|
|||
IBackgroundCopyJob* iface,
|
||||
BG_JOB_TYPE *pVal)
|
||||
{
|
||||
FIXME("Not implemented\n");
|
||||
return E_NOTIMPL;
|
||||
BackgroundCopyJobImpl *This = (BackgroundCopyJobImpl *) iface;
|
||||
|
||||
if (!pVal)
|
||||
return E_INVALIDARG;
|
||||
|
||||
*pVal = This->type;
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI BITS_IBackgroundCopyJob_GetProgress(
|
||||
|
|
|
@ -83,12 +83,29 @@ static void test_GetId(void)
|
|||
ok(memcmp(&tmpId, &test_jobId, sizeof tmpId) == 0, "Got incorrect GUID\n");
|
||||
}
|
||||
|
||||
/* Test that the type is properly set */
|
||||
static void test_GetType(void)
|
||||
{
|
||||
HRESULT hres;
|
||||
BG_JOB_TYPE type;
|
||||
|
||||
hres = IBackgroundCopyJob_GetType(test_job, &type);
|
||||
ok(hres == S_OK, "GetType failed: %08x\n", hres);
|
||||
if(hres != S_OK)
|
||||
{
|
||||
skip("Unable to get type of test_job.\n");
|
||||
return;
|
||||
}
|
||||
ok(type == test_type, "Got incorrect type\n");
|
||||
}
|
||||
|
||||
typedef void (*test_t)(void);
|
||||
|
||||
START_TEST(job)
|
||||
{
|
||||
static const test_t tests[] = {
|
||||
test_GetId,
|
||||
test_GetType,
|
||||
0
|
||||
};
|
||||
const test_t *test;
|
||||
|
|
Loading…
Reference in New Issue