Add a task queue into pc e2e fixture implementation
Bug: webrtc:10138 Change-Id: I0337df78c601cac2b5f2749e15369bd87221134d Reviewed-on: https://webrtc-review.googlesource.com/c/123446 Commit-Queue: Artem Titov <titovartem@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/master@{#26762}
This commit is contained in:
parent
e82643fb9c
commit
0b2150c884
@ -216,6 +216,7 @@ if (rtc_include_tests) {
|
||||
"../../../rtc_base:gunit_helpers",
|
||||
"../../../rtc_base:rtc_base",
|
||||
"../../../rtc_base:rtc_base_approved",
|
||||
"../../../rtc_base:rtc_task_queue",
|
||||
"../../../rtc_base:safe_conversions",
|
||||
"../../../system_wrappers:system_wrappers",
|
||||
"../../../test:fileutils",
|
||||
|
||||
@ -1,5 +1,3 @@
|
||||
#include <utility>
|
||||
|
||||
/*
|
||||
* Copyright (c) 2019 The WebRTC project authors. All Rights Reserved.
|
||||
*
|
||||
@ -94,7 +92,7 @@ class FixturePeerConnectionObserver : public MockPeerConnectionObserver {
|
||||
|
||||
PeerConnectionE2EQualityTest::PeerConnectionE2EQualityTest(
|
||||
std::unique_ptr<Analyzers> analyzers)
|
||||
: clock_(Clock::GetRealTimeClock()) {
|
||||
: clock_(Clock::GetRealTimeClock()), task_queue_("pc_e2e_quality_test") {
|
||||
RTC_CHECK(analyzers);
|
||||
|
||||
// Create default video quality analyzer. We will always create an analyzer,
|
||||
|
||||
@ -15,6 +15,7 @@
|
||||
#include <vector>
|
||||
|
||||
#include "pc/test/frame_generator_capturer_video_track_source.h"
|
||||
#include "rtc_base/task_queue.h"
|
||||
#include "rtc_base/thread.h"
|
||||
#include "system_wrappers/include/clock.h"
|
||||
#include "test/pc/e2e/analyzer/video/single_process_encoded_image_id_injector.h"
|
||||
@ -92,6 +93,10 @@ class PeerConnectionE2EQualityTest
|
||||
std::vector<std::unique_ptr<VideoFrameWriter>> video_writers_;
|
||||
std::vector<std::unique_ptr<rtc::VideoSinkInterface<VideoFrame>>>
|
||||
output_video_sinks_;
|
||||
|
||||
// Must be the last field, so it will be deleted first, because tasks
|
||||
// in the TaskQueue can access other fields of the instance of this class.
|
||||
rtc::TaskQueue task_queue_;
|
||||
};
|
||||
|
||||
} // namespace test
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user