Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(144)

Unified Diff: webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc

Issue 2341293002: Add new decoding statistics for muted output (Closed)
Patch Set: Updates after reviews Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/modules/audio_coding/acm2/call_statistics.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc
diff --git a/webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc b/webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc
index 9ba0774ce1c478e93e8e73ff885a889515a37573..284532fbfd7ec4a53c6067c943399940261aed07 100644
--- a/webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc
+++ b/webrtc/modules/audio_coding/acm2/call_statistics_unittest.cc
@@ -26,6 +26,7 @@ TEST(CallStatisticsTest, InitializedZero) {
EXPECT_EQ(0, stats.decoded_cng);
EXPECT_EQ(0, stats.decoded_plc);
EXPECT_EQ(0, stats.decoded_plc_cng);
+ EXPECT_EQ(0, stats.decoded_muted_output);
}
TEST(CallStatisticsTest, AllCalls) {
@@ -33,10 +34,10 @@ TEST(CallStatisticsTest, AllCalls) {
AudioDecodingCallStats stats;
call_stats.DecodedBySilenceGenerator();
- call_stats.DecodedByNetEq(AudioFrame::kNormalSpeech);
- call_stats.DecodedByNetEq(AudioFrame::kPLC);
- call_stats.DecodedByNetEq(AudioFrame::kPLCCNG);
- call_stats.DecodedByNetEq(AudioFrame::kCNG);
+ call_stats.DecodedByNetEq(AudioFrame::kNormalSpeech, false);
+ call_stats.DecodedByNetEq(AudioFrame::kPLC, false);
+ call_stats.DecodedByNetEq(AudioFrame::kPLCCNG, true); // Let this be muted.
+ call_stats.DecodedByNetEq(AudioFrame::kCNG, false);
stats = call_stats.GetDecodingStatistics();
EXPECT_EQ(4, stats.calls_to_neteq);
@@ -45,6 +46,7 @@ TEST(CallStatisticsTest, AllCalls) {
EXPECT_EQ(1, stats.decoded_cng);
EXPECT_EQ(1, stats.decoded_plc);
EXPECT_EQ(1, stats.decoded_plc_cng);
+ EXPECT_EQ(1, stats.decoded_muted_output);
}
} // namespace acm2
« no previous file with comments | « webrtc/modules/audio_coding/acm2/call_statistics.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698