mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-19 16:47:50 +01:00
Call Call::GetStats() from the correct thread in StatsEndToEndTest.
Bug: webrtc:10847 Change-Id: I8a82709073827f0eb901e20600f4e8bcf86d96a3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/148061 Reviewed-by: Magnus Flodman <mflodman@webrtc.org> Commit-Queue: Tommi <tommi@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28786}
This commit is contained in:
parent
c24a5b18ba
commit
d23f67e6be
1 changed files with 3 additions and 1 deletions
|
@ -749,7 +749,9 @@ TEST_F(StatsEndToEndTest, CallReportsRttForSender) {
|
||||||
|
|
||||||
int64_t start_time_ms = clock_->TimeInMilliseconds();
|
int64_t start_time_ms = clock_->TimeInMilliseconds();
|
||||||
while (true) {
|
while (true) {
|
||||||
Call::Stats stats = sender_call_->GetStats();
|
Call::Stats stats;
|
||||||
|
task_queue_.SendTask(
|
||||||
|
[this, &stats]() { stats = sender_call_->GetStats(); });
|
||||||
ASSERT_GE(start_time_ms + kDefaultTimeoutMs, clock_->TimeInMilliseconds())
|
ASSERT_GE(start_time_ms + kDefaultTimeoutMs, clock_->TimeInMilliseconds())
|
||||||
<< "No RTT stats before timeout!";
|
<< "No RTT stats before timeout!";
|
||||||
if (stats.rtt_ms != -1) {
|
if (stats.rtt_ms != -1) {
|
||||||
|
|
Loading…
Reference in a new issue