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

Unified Diff: webrtc/pc/peerconnection_integrationtest.cc

Issue 3008273002: Replace voe_conference_test. (Closed)
Patch Set: rebase Created 3 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/audio/test/low_bandwidth_audio_test.cc ('k') | webrtc/pc/test/mockpeerconnectionobservers.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/pc/peerconnection_integrationtest.cc
diff --git a/webrtc/pc/peerconnection_integrationtest.cc b/webrtc/pc/peerconnection_integrationtest.cc
index 641be6f7f227f18dd4f5b667bcb5920ff75c3bb4..6760b14322902214dfd0943d2fb60fab5798b929 100644
--- a/webrtc/pc/peerconnection_integrationtest.cc
+++ b/webrtc/pc/peerconnection_integrationtest.cc
@@ -1914,6 +1914,33 @@ TEST_F(PeerConnectionIntegrationTest, GetBytesSentStatsWithOldStatsApi) {
EXPECT_GT(caller()->OldGetStatsForTrack(video_track)->BytesSent(), 0);
}
+// Test that we can get capture start ntp time.
+TEST_F(PeerConnectionIntegrationTest, GetCaptureStartNtpTimeWithOldStatsApi) {
+ ASSERT_TRUE(CreatePeerConnectionWrappers());
+ ConnectFakeSignaling();
+ caller()->AddAudioOnlyMediaStream();
+
+ auto audio_track = callee()->CreateLocalAudioTrack();
+ callee()->AddMediaStreamFromTracks(audio_track, nullptr);
+
+ // Do offer/answer, wait for the callee to receive some frames.
+ caller()->CreateAndSetAndSignalOffer();
+ ASSERT_TRUE_WAIT(SignalingStateStable(), kDefaultTimeout);
+
+ // Get the remote audio track created on the receiver, so they can be used as
+ // GetStats filters.
+ StreamCollectionInterface* remote_streams = callee()->remote_streams();
+ ASSERT_EQ(1u, remote_streams->count());
+ ASSERT_EQ(1u, remote_streams->at(0)->GetAudioTracks().size());
+ MediaStreamTrackInterface* remote_audio_track =
+ remote_streams->at(0)->GetAudioTracks()[0];
+
+ // Get the audio output level stats. Note that the level is not available
+ // until an RTCP packet has been received.
+ EXPECT_TRUE_WAIT(callee()->OldGetStatsForTrack(remote_audio_track)->
+ CaptureStartNtpTime() > 0, 2 * kMaxWaitForFramesMs);
+}
+
// Test that we can get stats (using the new stats implemnetation) for
// unsignaled streams. Meaning when SSRCs/MSIDs aren't signaled explicitly in
// SDP.
« no previous file with comments | « webrtc/audio/test/low_bandwidth_audio_test.cc ('k') | webrtc/pc/test/mockpeerconnectionobservers.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698