From 05873dcaa6a3b7fc5dace9a249561fd7b82318be Mon Sep 17 00:00:00 2001 From: Byoungchan Lee Date: Fri, 10 Feb 2023 11:15:27 +0900 Subject: [PATCH] Makes use of the newer version of the RecordedDataIsAvailable mock When I run these tests locally, Gmock complained about the incorrect mock function call and caused the test to fail. Bug: None Change-Id: I37c9168650471b171a5d7f7b4e3a4c6c6225d618 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/292920 Reviewed-by: Henrik Andreassson Commit-Queue: Daniel.L (Byoungchan) Lee Cr-Commit-Position: refs/heads/main@{#39292} --- modules/audio_device/audio_device_unittest.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/audio_device/audio_device_unittest.cc b/modules/audio_device/audio_device_unittest.cc index 0a3a88c2e6..e03c11655b 100644 --- a/modules/audio_device/audio_device_unittest.cc +++ b/modules/audio_device/audio_device_unittest.cc @@ -1016,7 +1016,7 @@ TEST_P(MAYBE_AudioDeviceTest, StartStopRecordingWithInternalRestart) { MockAudioTransport mock(TransportType::kRecord); mock.HandleCallbacks(event(), nullptr, kNumCallbacks); EXPECT_CALL(mock, RecordedDataIsAvailable(NotNull(), _, _, _, _, Ge(0u), 0, _, - false, _)) + false, _, _)) .Times(AtLeast(kNumCallbacks)); EXPECT_EQ(0, audio_device()->RegisterAudioCallback(&mock)); StartRecording(); @@ -1042,7 +1042,7 @@ TEST_P(MAYBE_AudioDeviceTest, StartStopRecordingWithInternalRestart) { ASSERT_TRUE(Mock::VerifyAndClearExpectations(&mock)); mock.ResetCallbackCounters(); EXPECT_CALL(mock, RecordedDataIsAvailable(NotNull(), _, _, _, _, Ge(0u), 0, _, - false, _)) + false, _, _)) .Times(AtLeast(kNumCallbacks)); event()->Wait(kTestTimeOut); EXPECT_TRUE(audio_device()->Recording()); @@ -1094,7 +1094,7 @@ TEST_P(MAYBE_AudioDeviceTest, MAYBE_StartRecordingVerifyCallbacks) { MockAudioTransport mock(TransportType::kRecord); mock.HandleCallbacks(event(), nullptr, kNumCallbacks); EXPECT_CALL(mock, RecordedDataIsAvailable(NotNull(), _, _, _, _, Ge(0u), 0, _, - false, _)) + false, _, _)) .Times(AtLeast(kNumCallbacks)); EXPECT_EQ(0, audio_device()->RegisterAudioCallback(&mock)); StartRecording(); @@ -1112,7 +1112,7 @@ TEST_P(MAYBE_AudioDeviceTest, MAYBE_StartPlayoutAndRecordingVerifyCallbacks) { EXPECT_CALL(mock, NeedMorePlayData(_, _, _, _, NotNull(), _, _, _)) .Times(AtLeast(kNumCallbacks)); EXPECT_CALL(mock, RecordedDataIsAvailable(NotNull(), _, _, _, _, Ge(0u), 0, _, - false, _)) + false, _, _)) .Times(AtLeast(kNumCallbacks)); EXPECT_EQ(0, audio_device()->RegisterAudioCallback(&mock)); StartPlayout();