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
d930a0cc
Commit
d930a0cc
authored
Jul 12, 2022
by
Claire Girka
Committed by
Alexandre Julliard
Jul 25, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntoskrnl/tests: Add test for getting SPDRP_BASE_CONTAINERID from PnP driver.
parent
f7f109d9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
1 deletion
+10
-1
driver_pnp.c
dlls/ntoskrnl.exe/tests/driver_pnp.c
+4
-1
ntoskrnl.c
dlls/ntoskrnl.exe/tests/ntoskrnl.c
+6
-0
No files found.
dlls/ntoskrnl.exe/tests/driver_pnp.c
View file @
d930a0cc
...
...
@@ -228,7 +228,10 @@ static NTSTATUS query_id(struct device *device, IRP *irp, BUS_QUERY_ID_TYPE type
}
case
BusQueryContainerID
:
return
STATUS_NOT_SUPPORTED
;
if
(
!
(
id
=
ExAllocatePool
(
PagedPool
,
39
*
sizeof
(
WCHAR
))))
return
STATUS_NO_MEMORY
;
wcscpy
(
id
,
L"{12345678-1234-1234-1234-123456789123}"
);
break
;
default:
ok
(
0
,
"Unexpected ID query type %#x.
\n
"
,
type
);
...
...
dlls/ntoskrnl.exe/tests/ntoskrnl.c
View file @
d930a0cc
...
...
@@ -1462,6 +1462,7 @@ static void test_pnp_devices(void)
static
const
char
expect_compat_id
[]
=
"winetest_compat
\0
winetest_compat_1
\0
"
;
char
buffer
[
200
];
WCHAR
buffer_w
[
200
];
SP_DEVICE_INTERFACE_DETAIL_DATA_A
*
iface_detail
=
(
void
*
)
buffer
;
SP_DEVICE_INTERFACE_DATA
iface
=
{
sizeof
(
iface
)};
SP_DEVINFO_DATA
device
=
{
sizeof
(
device
)};
...
...
@@ -1646,6 +1647,11 @@ static void test_pnp_devices(void)
ok
(
size
==
sizeof
(
expect_hardware_id
),
"got size %lu
\n
"
,
size
);
ok
(
!
memcmp
(
buffer
,
expect_hardware_id
,
size
),
"got hardware IDs %s
\n
"
,
debugstr_an
(
buffer
,
size
));
/* Using the WCHAR variant because Windows returns a WCHAR for this property even when using SetupDiGetDeviceRegistryPropertyA */
ret
=
SetupDiGetDeviceRegistryPropertyW
(
set
,
&
device
,
SPDRP_BASE_CONTAINERID
,
&
type
,
(
BYTE
*
)
buffer_w
,
sizeof
(
buffer_w
),
&
size
);
todo_wine
ok
(
ret
,
"got error %#lx
\n
"
,
GetLastError
());
ret
=
SetupDiGetDeviceRegistryPropertyA
(
set
,
&
device
,
SPDRP_COMPATIBLEIDS
,
&
type
,
(
BYTE
*
)
buffer
,
sizeof
(
buffer
),
&
size
);
ok
(
ret
,
"got error %#lx
\n
"
,
GetLastError
());
...
...
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