Skip to content

[NTS] Fast Playback test case failures - #523

Open
Koky2701 wants to merge 4 commits into
masterfrom
feature/RDKEMW-15056
Open

[NTS] Fast Playback test case failures#523
Koky2701 wants to merge 4 commits into
masterfrom
feature/RDKEMW-15056

Conversation

@Koky2701

@Koky2701 Koky2701 commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Summary: Fix premature underflow signal when buffer is still rendering frames
Type: Fix
Test Plan: UT/CT, Fullstack
Jira: RDKEMW-15056

Copilot AI review requested due to automatic review settings June 9, 2026 11:54
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

Pull request title must follow the pattern:
< JIRA TICKET >: < one line summary of change less than 65 characters >

Pull request description must follow the Commit message format for RDK-E:
https://etwiki.sys.comcast.net/spaces/RDKAR/pages/1407997180/Commit+Message+Format+For+RDKE

  1. Associated JIRA ticket in format : < JIRA TICKET >: < one line summary of change less than 65 characters >
  2. Detailed reason for change information
  3. Test procedure. Only references links to Jira ticket or sub tickets where test steps and references are captured.

< JIRA TICKET >: < one line summary of change less than 65 characters >
< empty line >
Reason for change:
Test Procedure: < https://ccp.sys.comcast.net/browse/JIRA TICKET/url/to/test_step_section>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes premature audio/video underflow reporting in the GStreamer generic player setup by ignoring underflow callbacks while the sink/decoder still reports buffered frames (non-zero FIFO depth). This aligns underflow signaling with actual depletion and prevents fast-playback-related test failures.

Changes:

  • Guard audio/video underflow callbacks to no-op when fifoDepth > 0.
  • Add unit tests asserting underflow is not scheduled when fifoDepth is non-zero for both audio and video.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
media/server/gstplayer/source/tasks/generic/SetupElement.cpp Ignores underflow callbacks when FIFO depth is non-zero to prevent premature underflow scheduling.
tests/unittests/media/server/gstplayer/genericPlayer/tasksTests/SetupElementTest.cpp Adds unit coverage for the new “ignore underflow when fifoDepth > 0” behavior for audio and video.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from d11ae39 to e38c32a Compare June 18, 2026 13:57
Copilot AI review requested due to automatic review settings June 18, 2026 14:27
@github-actions

Copy link
Copy Markdown

tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:263:5: performance: Variable 'testContext' is assigned in constructor body. Consider performing initialization in initialization list. [useInitializationList]
testContext = std::make_shared();
^
tests/unittests/media/server/gstplayer/genericPlayer/tasksTests/SetupElementTest.cpp:174:1: error: Unmatched '{'. Configuration: ''. [syntaxError]
{
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:749:0: style: The function 'shouldSetupVideoSinkElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:760:0: style: The function 'shouldSetupVideoDecoderElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:771:0: style: The function 'shouldSetupVideoDecoderElementWithFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderElementWithFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:782:0: style: The function 'shouldSetupVideoElementWithPendingGeometry' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementWithPendingGeometry()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:796:0: style: The function 'shouldSetupVideoElementWithPendingImmediateOutput' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementWithPendingImmediateOutput()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:810:0: style: The function 'shouldSetupAudioSinkElementWithPendingLowLatency' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementWithPendingLowLatency()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:825:0: style: The function 'shouldSetupAudioSinkElementWithPendingSync' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementWithPendingSync()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:840:0: style: The function 'shouldSetupAudioDecoderElementWithPendingSyncOff' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingSyncOff()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:851:0: style: The function 'shouldSetupAudioDecoderElementWithPendingStreamSyncMode' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingStreamSyncMode()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:862:0: style: The function 'shouldSetupVideoParserElementWithPendingStreamSyncMode' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoParserElementWithPendingStreamSyncMode()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:873:0: style: The function 'shouldSetupAudioDecoderElementWithPendingBufferingLimit' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingBufferingLimit()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:884:0: style: The function 'shouldSetupAudioDecoderElementWithIsLiveParameter' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithIsLiveParameter()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:899:0: style: The function 'shouldSetupVideoSinkElementWithPendingRenderFrame' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementWithPendingRenderFrame()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:914:0: style: The function 'shouldSetupVideoSinkElementWithPendingShowVideoWindow' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementWithPendingShowVideoWindow()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:929:0: style: The function 'shouldSetupAudioElementAmlhalasinkWhenVideoExists' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAmlhalasinkWhenVideoExists()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:942:0: style: The function 'shouldSetupAudioElementAmlhalasinkWhenNoVideo' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAmlhalasinkWhenNoVideo()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:952:0: style: The function 'shouldSetupAudioElementBrcmAudioSink' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementBrcmAudioSink()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:989:0: style: The function 'shouldSetupVideoElementAutoVideoSinkWithMultipleChildren' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementAutoVideoSinkWithMultipleChildren()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:995:0: style: The function 'shouldSetupAudioElementAutoAudioSinkWithMultipleChildren' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAutoAudioSinkWithMultipleChildren()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1065:0: style: The function 'shouldSetupAudioSinkElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1076:0: style: The function 'shouldSetupAudioDecoderElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1084:0: style: The function 'shouldSetVideoUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetVideoUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1090:0: style: The function 'shouldSetFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1096:0: style: The function 'shouldSetupBaseParse' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupBaseParse()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1102:0: style: The function 'triggerVideoUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerVideoUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1108:0: style: The function 'triggerFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1114:0: style: The function 'shouldSetAudioUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetAudioUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1120:0: style: The function 'triggerAudioUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAudioUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1126:0: style: The function 'shouldAddAutoVideoSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddAutoVideoSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1131:0: style: The function 'shouldAddAutoAudioSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddAutoAudioSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1136:0: style: The function 'triggerAutoVideoSinkChildAddedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoVideoSinkChildAddedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1144:0: style: The function 'triggerAutoAudioSinkChildAddedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoAudioSinkChildAddedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1152:0: style: The function 'shouldRemoveAutoVideoSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldRemoveAutoVideoSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1157:0: style: The function 'shouldRemoveAutoAudioSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldRemoveAutoAudioSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1162:0: style: The function 'triggerAutoVideoSinkChildRemovedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoVideoSinkChildRemovedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1170:0: style: The function 'triggerAutoAudioSinkChildRemovedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoAudioSinkChildRemovedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1204:0: style: The function 'shouldAddFirstAutoVideoSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddFirstAutoVideoSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1212:0: style: The function 'shouldAddFirstAutoAudioSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddFirstAutoAudioSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1220:0: style: The function 'shouldNotAddAutoVideoSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldNotAddAutoVideoSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1226:0: style: The function 'shouldNotAddAutoAudioSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldNotAddAutoAudioSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3614:0: style: The function 'shouldSetupTextTrackSink' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupTextTrackSink()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3629:0: style: The function 'shouldSetupVideoDecoderForTextTrack' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrack()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3654:0: style: The function 'shouldSetupVideoDecoderForTextTrackWesterosSinkWithDecoder' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrackWesterosSinkWithDecoder()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3685:0: style: The function 'shouldSetupVideoDecoderForTextTrackWesterosSinkWithoutDecoder' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrackWesterosSinkWithoutDecoder()
^
nofile:0:0: information: Active checkers: There was critical errors (use --checkers-report= to see details) [checkersReport]

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

Comment on lines +173 to +180
TEST_F(SetupElementTest, shouldNotReportVideoUnderflowWhenFifoDepthIsNonZero)
{
shouldSetupVideoDecoderElementOnly();
triggerSetupElement();

ASSERT_TRUE(testContext->m_videoUnderflowCallback);
EXPECT_CALL(testContext->m_gstPlayer, scheduleVideoUnderflow()).Times(0);

@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from f48c93a to 0d2a258 Compare June 18, 2026 14:39
Copilot AI review requested due to automatic review settings June 18, 2026 14:41

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

Comment on lines 181 to 184
auto videoUnderflowCallback = reinterpret_cast<void (*)(GstElement *, guint, gpointer, gpointer)>(
testContext->m_videoUnderflowCallback);
videoUnderflowCallback(testContext->m_element, 1, nullptr, &testContext->m_gstPlayer);
TEST_F(SetupElementTest, shouldReportFirstVideoFrame)
@github-actions

Copy link
Copy Markdown

tests/unittests/media/server/gstplayer/genericPlayer/tasksTests/SetupElementTest.cpp:174:1: error: Unmatched '{'. Configuration: ''. [syntaxError]
{
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:748:0: style: The function 'shouldSetupVideoSinkElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:759:0: style: The function 'shouldSetupVideoDecoderElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:770:0: style: The function 'shouldSetupVideoDecoderElementWithFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderElementWithFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:781:0: style: The function 'shouldSetupVideoElementWithPendingGeometry' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementWithPendingGeometry()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:795:0: style: The function 'shouldSetupVideoElementWithPendingImmediateOutput' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementWithPendingImmediateOutput()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:809:0: style: The function 'shouldSetupAudioSinkElementWithPendingLowLatency' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementWithPendingLowLatency()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:824:0: style: The function 'shouldSetupAudioSinkElementWithPendingSync' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementWithPendingSync()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:839:0: style: The function 'shouldSetupAudioDecoderElementWithPendingSyncOff' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingSyncOff()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:850:0: style: The function 'shouldSetupAudioDecoderElementWithPendingStreamSyncMode' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingStreamSyncMode()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:861:0: style: The function 'shouldSetupVideoParserElementWithPendingStreamSyncMode' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoParserElementWithPendingStreamSyncMode()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:872:0: style: The function 'shouldSetupAudioDecoderElementWithPendingBufferingLimit' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithPendingBufferingLimit()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:883:0: style: The function 'shouldSetupAudioDecoderElementWithIsLiveParameter' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementWithIsLiveParameter()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:898:0: style: The function 'shouldSetupVideoSinkElementWithPendingRenderFrame' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementWithPendingRenderFrame()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:913:0: style: The function 'shouldSetupVideoSinkElementWithPendingShowVideoWindow' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoSinkElementWithPendingShowVideoWindow()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:928:0: style: The function 'shouldSetupAudioElementAmlhalasinkWhenVideoExists' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAmlhalasinkWhenVideoExists()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:941:0: style: The function 'shouldSetupAudioElementAmlhalasinkWhenNoVideo' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAmlhalasinkWhenNoVideo()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:951:0: style: The function 'shouldSetupAudioElementBrcmAudioSink' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementBrcmAudioSink()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:988:0: style: The function 'shouldSetupVideoElementAutoVideoSinkWithMultipleChildren' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoElementAutoVideoSinkWithMultipleChildren()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:994:0: style: The function 'shouldSetupAudioElementAutoAudioSinkWithMultipleChildren' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioElementAutoAudioSinkWithMultipleChildren()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1064:0: style: The function 'shouldSetupAudioSinkElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioSinkElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1075:0: style: The function 'shouldSetupAudioDecoderElementOnly' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupAudioDecoderElementOnly()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1083:0: style: The function 'shouldSetVideoUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetVideoUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1089:0: style: The function 'shouldSetFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1095:0: style: The function 'shouldSetupBaseParse' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupBaseParse()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1101:0: style: The function 'triggerVideoUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerVideoUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1107:0: style: The function 'triggerFirstVideoFrameCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerFirstVideoFrameCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1113:0: style: The function 'shouldSetAudioUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetAudioUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1119:0: style: The function 'triggerAudioUnderflowCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAudioUnderflowCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1125:0: style: The function 'shouldAddAutoVideoSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddAutoVideoSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1130:0: style: The function 'shouldAddAutoAudioSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddAutoAudioSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1135:0: style: The function 'triggerAutoVideoSinkChildAddedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoVideoSinkChildAddedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1143:0: style: The function 'triggerAutoAudioSinkChildAddedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoAudioSinkChildAddedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1151:0: style: The function 'shouldRemoveAutoVideoSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldRemoveAutoVideoSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1156:0: style: The function 'shouldRemoveAutoAudioSinkChildCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldRemoveAutoAudioSinkChildCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1161:0: style: The function 'triggerAutoVideoSinkChildRemovedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoVideoSinkChildRemovedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1169:0: style: The function 'triggerAutoAudioSinkChildRemovedCallback' is never used. [unusedFunction]
void GenericTasksTestsBase::triggerAutoAudioSinkChildRemovedCallback()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1203:0: style: The function 'shouldAddFirstAutoVideoSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddFirstAutoVideoSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1211:0: style: The function 'shouldAddFirstAutoAudioSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldAddFirstAutoAudioSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1219:0: style: The function 'shouldNotAddAutoVideoSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldNotAddAutoVideoSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:1225:0: style: The function 'shouldNotAddAutoAudioSinkChild' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldNotAddAutoAudioSinkChild()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3613:0: style: The function 'shouldSetupTextTrackSink' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupTextTrackSink()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3628:0: style: The function 'shouldSetupVideoDecoderForTextTrack' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrack()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3653:0: style: The function 'shouldSetupVideoDecoderForTextTrackWesterosSinkWithDecoder' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrackWesterosSinkWithDecoder()
^
tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.cpp:3684:0: style: The function 'shouldSetupVideoDecoderForTextTrackWesterosSinkWithoutDecoder' is never used. [unusedFunction]
void GenericTasksTestsBase::shouldSetupVideoDecoderForTextTrackWesterosSinkWithoutDecoder()
^
nofile:0:0: information: Active checkers: There was critical errors (use --checkers-report= to see details) [checkersReport]

@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from b56c353 to 1450d87 Compare June 18, 2026 14:52
Copilot AI review requested due to automatic review settings June 18, 2026 15:39
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from 1450d87 to 599a0a5 Compare June 18, 2026 15:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

Comment on lines +178 to +182
ASSERT_TRUE(testContext->m_videoUnderflowCallback);
EXPECT_CALL(testContext->m_gstPlayer, scheduleVideoUnderflow()).Times(0);

triggerVideoUnderflowCallback();
}
Comment on lines +207 to +211
ASSERT_TRUE(testContext->m_audioUnderflowCallback);
EXPECT_CALL(testContext->m_gstPlayer, scheduleAudioUnderflow()).Times(0);

triggerAudioUnderflowCallback();
}
Comment on lines +29 to +33
#include <memory>
#include <string>

#include "GenericTasksTestsContext.h"

@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch 2 times, most recently from 1c5fafb to ddce17b Compare June 24, 2026 13:43
Copilot AI review requested due to automatic review settings June 24, 2026 13:43

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

Comment on lines +42 to +46
if (fifoDepth > 0)
{
RIALTO_SERVER_LOG_DEBUG("Ignoring audio underflow callback - fifoDepth is %u", fifoDepth);
return;
}
Comment on lines +65 to +69
if (fifoDepth > 0)
{
RIALTO_SERVER_LOG_DEBUG("Ignoring video underflow callback - fifoDepth is %u", fifoDepth);
return;
}
@github-actions

Copy link
Copy Markdown

Coverage statistics of your commit:
Lines coverage stays unchanged and is: 84.2%
Functions coverage stays unchanged and is: 92.6%

@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from ddce17b to e832f8d Compare June 24, 2026 14:06
@github-actions

Copy link
Copy Markdown

Coverage statistics of your commit:
Lines coverage stays unchanged and is: 84.2%
Functions coverage stays unchanged and is: 92.6%

1 similar comment
@github-actions

Copy link
Copy Markdown

Coverage statistics of your commit:
Lines coverage stays unchanged and is: 84.2%
Functions coverage stays unchanged and is: 92.6%

Copilot AI review requested due to automatic review settings July 6, 2026 11:00
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from bdbe3ed to 5cb1188 Compare July 6, 2026 11:00

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Suppressed comments (4)

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:73

  • videoUnderflowCallback ignores the queueDepth argument, so it will still schedule an underflow when fifoDepth == 0 but queueDepth > 0 (which means there are still frames queued). This also makes the new queue-depth unit test impossible to satisfy.
    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

tests/unittests/media/server/gstplayer/genericPlayer/tasksTests/SetupElementTest.cpp:197

  • This test passes a non-null queueDepth pointer and expects underflow not to be scheduled, but the callback path will also call isVideoHandleSet() when depth is non-zero. Because m_gstPlayer is a StrictMock, the test should set an expectation for isVideoHandleSet() (and return true).
    ASSERT_TRUE(testContext->m_videoUnderflowCallback);
    EXPECT_CALL(testContext->m_gstPlayer, scheduleVideoUnderflow()).Times(0);

    guint queueDepth = 1;
    auto videoUnderflowCallback = reinterpret_cast<void (*)(GstElement *, guint, gpointer, gpointer)>(
        testContext->m_videoUnderflowCallback);
    videoUnderflowCallback(testContext->m_element, 0, &queueDepth, &testContext->m_gstPlayer);

media/server/gstplayer/source/GstGenericPlayer.cpp:1889

  • GstGenericPlayer::isVideoHandleSet() is defined here, but there is no corresponding method declaration/override in media/server/gstplayer/include/GstGenericPlayer.h. As written, this out-of-line definition will not compile, and the class also won’t satisfy the new pure-virtual method on IGstGenericPlayerPrivate.
bool GstGenericPlayer::isVideoHandleSet() const
{
    return m_context.isVideoHandleSet;
}

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:52

  • audioUnderflowCallback also ignores the queueDepth argument; if GStreamer reports fifoDepth == 0 but the queue depth is still non-zero, this will still schedule an underflow prematurely.

This issue also appears on line 70 of the same file.

    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

Comment on lines +223 to +227
ASSERT_TRUE(testContext->m_audioUnderflowCallback);
EXPECT_CALL(testContext->m_gstPlayer, scheduleAudioUnderflow()).Times(0);

auto audioUnderflowCallback = reinterpret_cast<void (*)(GstElement *, guint, gpointer, gpointer)>(
testContext->m_audioUnderflowCallback);
Copilot AI review requested due to automatic review settings July 31, 2026 07:49
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from acff4de to 844084a Compare July 31, 2026 07:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.

Suppressed comments (2)

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:74

  • Video underflow suppression currently only checks fifoDepth (and also gates it on isVideoHandleSet()), but the signal also provides queueDepth. As written, underflow will still be scheduled when fifoDepth == 0 but queueDepth > 0 (buffer still has queued frames). Underflow should only be scheduled when both fifoDepth and queueDepth are zero.
    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:52

  • The underflow callback ignores the provided queueDepth and only suppresses underflow when isVideoHandleSet() is true. This means underflow can still be scheduled even when the sink reports buffered data (fifoDepth/queueDepth > 0), and it also introduces a StrictMock failure in unit tests when fifoDepth > 0 (uninteresting isVideoHandleSet() call). Consider treating underflow as real only when both fifoDepth and queueDepth are zero, independent of subtitle/video-handle state.

This issue also appears on line 70 of the same file.

    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

Copilot AI review requested due to automatic review settings July 31, 2026 08:14
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from 844084a to 24ea018 Compare July 31, 2026 08:14

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.

Suppressed comments (2)

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:73

  • videoUnderflowCallback ignores the queueDepth argument, so a non-zero queue depth will still schedule underflow (contradicting the new test shouldNotReportVideoUnderflowWhenQueueDepthIsNonZero). Incorporate queueDepth into the early-return condition so underflow is not reported while either fifo or queue still contains data.
    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:49

  • audioUnderflowCallback suppresses underflow only when fifoDepth > 0 and isVideoHandleSet() is true. This (a) still reports underflow when queueDepth is non-zero, and (b) calls isVideoHandleSet() for audio underflow (which also breaks the new unit test expecting no additional mock calls when fifoDepth is non-zero). Consider treating any non-zero fifo/queue depth as “not underflow” for audio, without consulting the video-handle state.

This issue also appears on line 70 of the same file.

    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

Copilot AI review requested due to automatic review settings July 31, 2026 08:23
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from 24ea018 to 6ae62ab Compare July 31, 2026 08:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.

Suppressed comments (3)

tests/unittests/media/server/gstplayer/genericPlayer/common/GenericTasksTestsBase.h:33

  • GenericTasksTestsBase.h includes GenericTasksTestsContext.h but also forward-declares GenericTasksTestsContext. Since the header only stores a std::shared_ptr, the forward declaration is sufficient and the include can be dropped to avoid pulling the full context into every test translation unit.
#include "GenericTasksTestsContext.h"

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:73

  • videoUnderflowCallback ignores the queueDepth argument. The updated unit test passes fifoDepth=0 with non-zero queueDepth and expects underflow NOT to be scheduled; with the current code scheduleVideoUnderflow() will still be called.
    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:50

  • audioUnderflowCallback currently calls isVideoHandleSet() and only suppresses underflow when that returns true. This makes audio-underflow suppression depend on a video-specific flag and also triggers an unexpected StrictMock call in unit tests. It should ignore underflow whenever fifoDepth (or queueDepth) indicates buffered data, without consulting isVideoHandleSet().

This issue also appears on line 70 of the same file.

    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

    Summary: Fix premature underflow signal when buffer is still rendering frames
    Type: Fix
    Test Plan: UT/CT, Fullstack
    Jira: RDKEMW-15056
Copilot AI review requested due to automatic review settings July 31, 2026 08:42
@Koky2701
Koky2701 force-pushed the feature/RDKEMW-15056 branch from 6ae62ab to ec72e75 Compare July 31, 2026 08:42

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.

Suppressed comments (2)

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:74

  • videoUnderflowCallback ignores the queueDepth argument. This means underflow can be scheduled even when the queue still contains data (queueDepth > 0), and the new unit test that passes fifoDepth==0 with queueDepth==1 would fail. Incorporate queueDepth into the suppression condition so that non-zero fifoDepth OR queueDepth prevents scheduling underflow (when isVideoHandleSet() indicates the relevant handle is set).
    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

media/server/gstplayer/source/tasks/generic/SetupElement.cpp:50

  • audioUnderflowCallback currently gates the early-return on isVideoHandleSet(). This makes audio underflow reporting depend on a video/subtitle handle state and will still schedule audio underflow when fifoDepth > 0 in audio-only cases (and also causes unexpected isVideoHandleSet() calls in StrictMock tests). The callback should suppress underflow whenever fifoDepth (or queueDepth) is non-zero, without consulting isVideoHandleSet().

This issue also appears on line 70 of the same file.

    if (fifoDepth > 0 && player && player->isVideoHandleSet())
    {
        return;
    }

Copilot AI review requested due to automatic review settings August 4, 2026 11:31

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

Copilot AI review requested due to automatic review settings August 4, 2026 11:33

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

        Summary: Checking timestamps to verify whether there are skipped frames
        Type: Fix
        Test Plan: UT/CT, Fullstack
        Jira: RDKEMW-15056
Copilot AI review requested due to automatic review settings August 4, 2026 14:15

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.

Suppressed comments (2)

media/server/gstplayer/source/GstGenericPlayer.cpp:1439

  • This adds an INFO log for every buffer pushed. In steady-state playback this can be extremely chatty and may impact performance. Also, GST_BUFFER_{PTS,DTS,DURATION} can be GST_CLOCK_TIME_NONE (i.e., -1); casting to uint64_t will log a very large number, which is misleading during debugging.
            const auto pts = static_cast<uint64_t>(GST_BUFFER_PTS(buffer));
            const auto dts = static_cast<uint64_t>(GST_BUFFER_DTS(buffer));
            const auto duration = static_cast<uint64_t>(GST_BUFFER_DURATION(buffer));
            RIALTO_SERVER_LOG_INFO(
                "Pushing %s buffer to gst pipeline: pts=%" PRIu64 " dts=%" PRIu64 " duration=%" PRIu64,
                common::convertMediaSourceType(mediaType), pts, dts, duration);

media/server/gstplayer/source/GstGenericPlayer.cpp:1439

  • PR description says this is a functional fix for a premature underflow signal, but the only change here is adding per-buffer logging. If the underflow fix is implemented elsewhere, it isn't reflected in this PR diff; otherwise the PR description should be updated to match (or the actual underflow fix added).
            RIALTO_SERVER_LOG_INFO(
                "Pushing %s buffer to gst pipeline: pts=%" PRIu64 " dts=%" PRIu64 " duration=%" PRIu64,
                common::convertMediaSourceType(mediaType), pts, dts, duration);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants