summaryrefslogtreecommitdiffstats
path: root/third_party/libwebrtc/api/test
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/libwebrtc/api/test')
-rw-r--r--third_party/libwebrtc/api/test/create_network_emulation_manager.cc6
-rw-r--r--third_party/libwebrtc/api/test/create_network_emulation_manager.h4
-rw-r--r--third_party/libwebrtc/api/test/create_time_controller.cc13
-rw-r--r--third_party/libwebrtc/api/test/pclf/BUILD.gn1
-rw-r--r--third_party/libwebrtc/api/test/pclf/media_configuration.h1
-rw-r--r--third_party/libwebrtc/api/test/pclf/media_quality_test_params.h1
-rw-r--r--third_party/libwebrtc/api/test/pclf/peer_configurer.cc5
-rw-r--r--third_party/libwebrtc/api/test/pclf/peer_configurer.h2
-rw-r--r--third_party/libwebrtc/api/test/peerconnection_quality_test_fixture.h1
-rw-r--r--third_party/libwebrtc/api/test/video_quality_test_fixture.h2
10 files changed, 24 insertions, 12 deletions
diff --git a/third_party/libwebrtc/api/test/create_network_emulation_manager.cc b/third_party/libwebrtc/api/test/create_network_emulation_manager.cc
index f5d5a1bc88..14a7a6a171 100644
--- a/third_party/libwebrtc/api/test/create_network_emulation_manager.cc
+++ b/third_party/libwebrtc/api/test/create_network_emulation_manager.cc
@@ -13,15 +13,17 @@
#include <memory>
+#include "api/field_trials_view.h"
#include "test/network/network_emulation_manager.h"
namespace webrtc {
std::unique_ptr<NetworkEmulationManager> CreateNetworkEmulationManager(
TimeMode time_mode,
- EmulatedNetworkStatsGatheringMode stats_gathering_mode) {
+ EmulatedNetworkStatsGatheringMode stats_gathering_mode,
+ const FieldTrialsView* field_trials) {
return std::make_unique<test::NetworkEmulationManagerImpl>(
- time_mode, stats_gathering_mode);
+ time_mode, stats_gathering_mode, field_trials);
}
} // namespace webrtc
diff --git a/third_party/libwebrtc/api/test/create_network_emulation_manager.h b/third_party/libwebrtc/api/test/create_network_emulation_manager.h
index 941b2b1c52..2f2dfeda28 100644
--- a/third_party/libwebrtc/api/test/create_network_emulation_manager.h
+++ b/third_party/libwebrtc/api/test/create_network_emulation_manager.h
@@ -13,6 +13,7 @@
#include <memory>
+#include "api/field_trials_view.h"
#include "api/test/network_emulation_manager.h"
namespace webrtc {
@@ -21,7 +22,8 @@ namespace webrtc {
std::unique_ptr<NetworkEmulationManager> CreateNetworkEmulationManager(
TimeMode time_mode = TimeMode::kRealTime,
EmulatedNetworkStatsGatheringMode stats_gathering_mode =
- EmulatedNetworkStatsGatheringMode::kDefault);
+ EmulatedNetworkStatsGatheringMode::kDefault,
+ const FieldTrialsView* field_trials = nullptr);
} // namespace webrtc
diff --git a/third_party/libwebrtc/api/test/create_time_controller.cc b/third_party/libwebrtc/api/test/create_time_controller.cc
index 7523e05208..cbf1f09aa1 100644
--- a/third_party/libwebrtc/api/test/create_time_controller.cc
+++ b/third_party/libwebrtc/api/test/create_time_controller.cc
@@ -16,10 +16,10 @@
#include "absl/base/nullability.h"
#include "api/enable_media_with_defaults.h"
#include "api/environment/environment.h"
+#include "api/environment/environment_factory.h"
#include "api/peer_connection_interface.h"
#include "call/call.h"
-#include "call/rtp_transport_config.h"
-#include "call/rtp_transport_controller_send_factory_interface.h"
+#include "call/call_config.h"
#include "pc/media_factory.h"
#include "rtc_base/checks.h"
#include "system_wrappers/include/clock.h"
@@ -49,9 +49,12 @@ void EnableMediaWithDefaultsAndTimeController(
: clock_(clock), media_factory_(std::move(media_factory)) {}
std::unique_ptr<Call> CreateCall(const CallConfig& config) override {
- return Call::Create(config, clock_,
- config.rtp_transport_controller_send_factory->Create(
- config.ExtractTransportConfig(), clock_));
+ EnvironmentFactory env_factory(config.env);
+ env_factory.Set(clock_);
+
+ CallConfig config_with_custom_clock = config;
+ config_with_custom_clock.env = env_factory.Create();
+ return media_factory_->CreateCall(config_with_custom_clock);
}
std::unique_ptr<cricket::MediaEngineInterface> CreateMediaEngine(
diff --git a/third_party/libwebrtc/api/test/pclf/BUILD.gn b/third_party/libwebrtc/api/test/pclf/BUILD.gn
index 372ff51f49..4f62984e83 100644
--- a/third_party/libwebrtc/api/test/pclf/BUILD.gn
+++ b/third_party/libwebrtc/api/test/pclf/BUILD.gn
@@ -20,7 +20,6 @@ rtc_source_set("media_configuration") {
"../..:array_view",
"../..:audio_options_api",
"../..:audio_quality_analyzer_api",
- "../..:callfactory_api",
"../..:fec_controller_api",
"../..:frame_generator_api",
"../..:function_view",
diff --git a/third_party/libwebrtc/api/test/pclf/media_configuration.h b/third_party/libwebrtc/api/test/pclf/media_configuration.h
index 5c3440c293..ad29e17e7d 100644
--- a/third_party/libwebrtc/api/test/pclf/media_configuration.h
+++ b/third_party/libwebrtc/api/test/pclf/media_configuration.h
@@ -26,7 +26,6 @@
#include "api/array_view.h"
#include "api/audio/audio_mixer.h"
#include "api/audio_options.h"
-#include "api/call/call_factory_interface.h"
#include "api/fec_controller.h"
#include "api/function_view.h"
#include "api/media_stream_interface.h"
diff --git a/third_party/libwebrtc/api/test/pclf/media_quality_test_params.h b/third_party/libwebrtc/api/test/pclf/media_quality_test_params.h
index aad04c3eb6..8a3a13a33b 100644
--- a/third_party/libwebrtc/api/test/pclf/media_quality_test_params.h
+++ b/third_party/libwebrtc/api/test/pclf/media_quality_test_params.h
@@ -136,6 +136,7 @@ struct Params {
// provided into VideoEncoder::SetRates(...).
double video_encoder_bitrate_multiplier = 1.0;
+ PeerConnectionFactoryInterface::Options peer_connection_factory_options;
PeerConnectionInterface::RTCConfiguration rtc_configuration;
PeerConnectionInterface::RTCOfferAnswerOptions rtc_offer_answer_options;
BitrateSettings bitrate_settings;
diff --git a/third_party/libwebrtc/api/test/pclf/peer_configurer.cc b/third_party/libwebrtc/api/test/pclf/peer_configurer.cc
index 5e385452b1..ac0d02818f 100644
--- a/third_party/libwebrtc/api/test/pclf/peer_configurer.cc
+++ b/third_party/libwebrtc/api/test/pclf/peer_configurer.cc
@@ -205,6 +205,11 @@ PeerConfigurer* PeerConfigurer::SetAecDumpPath(absl::string_view path) {
params_->aec_dump_path = std::string(path);
return this;
}
+PeerConfigurer* PeerConfigurer::SetPCFOptions(
+ PeerConnectionFactoryInterface::Options options) {
+ params_->peer_connection_factory_options = std::move(options);
+ return this;
+}
PeerConfigurer* PeerConfigurer::SetRTCConfiguration(
PeerConnectionInterface::RTCConfiguration configuration) {
params_->rtc_configuration = std::move(configuration);
diff --git a/third_party/libwebrtc/api/test/pclf/peer_configurer.h b/third_party/libwebrtc/api/test/pclf/peer_configurer.h
index c0faf8573a..1c6fb4c0e6 100644
--- a/third_party/libwebrtc/api/test/pclf/peer_configurer.h
+++ b/third_party/libwebrtc/api/test/pclf/peer_configurer.h
@@ -158,6 +158,8 @@ class PeerConfigurer {
// If is set, an AEC dump will be saved in that location and it will be
// available for further analysis.
PeerConfigurer* SetAecDumpPath(absl::string_view path);
+ PeerConfigurer* SetPCFOptions(
+ PeerConnectionFactoryInterface::Options options);
PeerConfigurer* SetRTCConfiguration(
PeerConnectionInterface::RTCConfiguration configuration);
PeerConfigurer* SetRTCOfferAnswerOptions(
diff --git a/third_party/libwebrtc/api/test/peerconnection_quality_test_fixture.h b/third_party/libwebrtc/api/test/peerconnection_quality_test_fixture.h
index 034e13ff3b..7e19eb1629 100644
--- a/third_party/libwebrtc/api/test/peerconnection_quality_test_fixture.h
+++ b/third_party/libwebrtc/api/test/peerconnection_quality_test_fixture.h
@@ -26,7 +26,6 @@
#include "absl/types/optional.h"
#include "api/array_view.h"
#include "api/audio/audio_mixer.h"
-#include "api/call/call_factory_interface.h"
#include "api/fec_controller.h"
#include "api/function_view.h"
#include "api/media_stream_interface.h"
diff --git a/third_party/libwebrtc/api/test/video_quality_test_fixture.h b/third_party/libwebrtc/api/test/video_quality_test_fixture.h
index b45faef286..cbe547b60d 100644
--- a/third_party/libwebrtc/api/test/video_quality_test_fixture.h
+++ b/third_party/libwebrtc/api/test/video_quality_test_fixture.h
@@ -61,7 +61,7 @@ class VideoQualityTestFixtureInterface {
bool automatic_scaling = false;
std::string clip_path; // "Generator" to generate frames instead.
size_t capture_device_index = 0;
- SdpVideoFormat::Parameters sdp_params;
+ CodecParameterMap sdp_params;
double encoder_overshoot_factor = 0.0;
} video[2];
struct Audio {