diff --git a/api/test/peerconnection_quality_test_fixture.h b/api/test/peerconnection_quality_test_fixture.h index 7aedd2def4..031b795971 100644 --- a/api/test/peerconnection_quality_test_fixture.h +++ b/api/test/peerconnection_quality_test_fixture.h @@ -179,6 +179,14 @@ class PeerConnectionE2EQualityTestFixture { struct VideoConfig { VideoConfig(size_t width, size_t height, int32_t fps) : width(width), height(height), fps(fps) {} + VideoConfig(std::string stream_label, + size_t width, + size_t height, + int32_t fps) + : width(width), + height(height), + fps(fps), + stream_label(std::move(stream_label)) {} // Video stream width. const size_t width; @@ -247,6 +255,11 @@ class PeerConnectionE2EQualityTestFixture { kGenerated, kFile, }; + + AudioConfig() = default; + explicit AudioConfig(std::string stream_label) + : stream_label(std::move(stream_label)) {} + // Have to be unique among all specified configs for all peers in the call. // Will be auto generated if omitted. absl::optional stream_label; diff --git a/test/pc/e2e/peer_connection_e2e_smoke_test.cc b/test/pc/e2e/peer_connection_e2e_smoke_test.cc index 92104c7395..2c9df0cf2a 100644 --- a/test/pc/e2e/peer_connection_e2e_smoke_test.cc +++ b/test/pc/e2e/peer_connection_e2e_smoke_test.cc @@ -341,15 +341,13 @@ TEST_F(PeerConnectionE2EQualityTestSmokeTest, MAYBE_Svc) { std::pair network_links = CreateNetwork(); AddPeer(network_links.first, [](PeerConfigurer* alice) { - VideoConfig simulcast(1280, 720, 15); - simulcast.stream_label = "alice-svc"; + VideoConfig simulcast("alice-svc", 1280, 720, 15); // Because we have network with packets loss we can analyze only the // highest spatial layer in SVC mode. simulcast.simulcast_config = VideoSimulcastConfig(2, 1); alice->AddVideoConfig(std::move(simulcast)); - AudioConfig audio; - audio.stream_label = "alice-audio"; + AudioConfig audio("alice-audio"); audio.mode = AudioConfig::Mode::kFile; audio.input_file_name = test::ResourcePath("pc_quality_smoke_test_alice_source", "wav");