Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
fe171ec8
Commit
fe171ec8
authored
Oct 24, 2023
by
Rémi Bernon
Committed by
Alexandre Julliard
Nov 13, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmime/tests: Test that IDirectMusicPerformance_Stop clears messages.
parent
ddd877d1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
49 additions
and
0 deletions
+49
-0
dmime.c
dlls/dmime/tests/dmime.c
+49
-0
No files found.
dlls/dmime/tests/dmime.c
View file @
fe171ec8
...
...
@@ -3294,6 +3294,55 @@ static void test_notification_pmsg(void)
ok
(
hr
==
S_FALSE
,
"got %#lx
\n
"
,
hr
);
/* Stop finishes segment immediately and skips notification messages */
hr
=
IDirectMusicPerformance_AddNotificationType
(
performance
,
&
GUID_NOTIFICATION_SEGMENT
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicPerformance_PlaySegment
(
performance
,
segment
,
0
,
0
,
&
state
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicPerformance_GetTime
(
performance
,
NULL
,
&
music_time
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ret
=
test_tool_wait_message
(
tool
,
50
,
(
DMUS_PMSG
**
)
&
notif
);
ok
(
!
ret
,
"got %#lx
\n
"
,
ret
);
check_dmus_notification_pmsg
(
notif
,
music_time
,
DMUS_PMSGF_TOOL_IMMEDIATE
,
&
GUID_NOTIFICATION_SEGMENT
,
DMUS_NOTIFICATION_SEGSTART
,
state
);
hr
=
IDirectMusicPerformance_FreePMsg
(
performance
,
(
DMUS_PMSG
*
)
notif
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicPerformance_Stop
(
performance
,
NULL
,
NULL
,
0
,
DMUS_SEGF_DEFAULT
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicPerformance_RemoveNotificationType
(
performance
,
&
GUID_NOTIFICATION_SEGMENT
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ret
=
test_tool_wait_message
(
tool
,
50
,
&
msg
);
ok
(
!
ret
,
"got %#lx
\n
"
,
ret
);
ok
(
msg
->
dwType
==
DMUS_PMSGT_DIRTY
,
"got %#lx
\n
"
,
msg
->
dwType
);
hr
=
IDirectMusicPerformance_FreePMsg
(
performance
,
msg
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ret
=
test_tool_wait_message
(
tool
,
50
,
(
DMUS_PMSG
**
)
&
notif
);
todo_wine
ok
(
!
ret
,
"got %#lx
\n
"
,
ret
);
if
(
!
ret
)
{
check_dmus_notification_pmsg
(
notif
,
music_time
,
DMUS_PMSGF_TOOL_IMMEDIATE
,
&
GUID_NOTIFICATION_SEGMENT
,
DMUS_NOTIFICATION_SEGABORT
,
state
);
hr
=
IDirectMusicPerformance_FreePMsg
(
performance
,
(
DMUS_PMSG
*
)
notif
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
}
ret
=
test_tool_wait_message
(
tool
,
500
,
&
msg
);
ok
(
!
ret
,
"got %#lx
\n
"
,
ret
);
ok
(
msg
->
dwType
==
DMUS_PMSGT_DIRTY
,
"got dwType %#lx
\n
"
,
msg
->
dwType
);
hr
=
IDirectMusicPerformance_FreePMsg
(
performance
,
msg
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ret
=
test_tool_wait_message
(
tool
,
100
,
&
msg
);
ok
(
ret
==
WAIT_TIMEOUT
,
"got %#lx
\n
"
,
ret
);
IDirectMusicSegmentState_Release
(
state
);
/* CloseDown removes all notifications and notification messages */
hr
=
IDirectMusicPerformance_AddNotificationType
(
performance
,
&
GUID_NOTIFICATION_SEGMENT
);
...
...
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