Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
fabffe2b
Commit
fabffe2b
authored
Sep 29, 2013
by
Jeff Klein
Committed by
Alexandre Julliard
Oct 02, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mmdevapi/tests: Add some tests for MMDevPropStore_GetAt.
parent
5b47e9b3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
propstore.c
dlls/mmdevapi/tests/propstore.c
+29
-0
No files found.
dlls/mmdevapi/tests/propstore.c
View file @
fabffe2b
...
...
@@ -81,6 +81,34 @@ static void test_deviceinterface(IPropertyStore *store)
CoTaskMemFree
(
pv
.
u
.
pwszVal
);
}
static
void
test_getat
(
IPropertyStore
*
store
)
{
HRESULT
hr
;
DWORD
propcount
;
DWORD
prop
;
PROPERTYKEY
pkey
;
BOOL
found_name
=
FALSE
;
BOOL
found_desc
=
FALSE
;
char
temp
[
128
];
temp
[
sizeof
(
temp
)
-
1
]
=
0
;
hr
=
IPropertyStore_GetCount
(
store
,
&
propcount
);
ok
(
hr
==
S_OK
,
"Failed with %08x
\n
"
,
hr
);
ok
(
propcount
>
0
,
"Propcount %d should be greather than zero
\n
"
,
propcount
);
for
(
prop
=
0
;
prop
<
propcount
;
prop
++
)
{
hr
=
IPropertyStore_GetAt
(
store
,
prop
,
&
pkey
);
ok
(
hr
==
S_OK
,
"Failed with %08x
\n
"
,
hr
);
if
(
IsEqualPropertyKey
(
pkey
,
DEVPKEY_Device_FriendlyName
))
found_name
=
TRUE
;
if
(
IsEqualPropertyKey
(
pkey
,
DEVPKEY_Device_DeviceDesc
))
found_desc
=
TRUE
;
}
ok
(
found_name
==
TRUE
,
"DEVPKEY_Device_FriendlyName not found
\n
"
);
ok
(
found_desc
==
TRUE
,
"DEVPKEY_Device_DeviceDesc not found
\n
"
);
}
START_TEST
(
propstore
)
{
HRESULT
hr
;
...
...
@@ -127,6 +155,7 @@ START_TEST(propstore)
{
test_propertystore
(
store
);
test_deviceinterface
(
store
);
test_getat
(
store
);
IPropertyStore_Release
(
store
);
}
IMMDevice_Release
(
dev
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment