Bug 1864652 - Expose settings for Global Privacy Control. r=geckoview-reviewers,ohall...
[gecko.git] / third_party / libwebrtc / pc / local_audio_source_unittest.cc
blob76d3b366c3efaf7951a2e2f398980fa742971a0d
1 /*
2 * Copyright 2013 The WebRTC project authors. All Rights Reserved.
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
11 #include "pc/local_audio_source.h"
13 #include "absl/types/optional.h"
14 #include "test/gtest.h"
16 using webrtc::LocalAudioSource;
18 TEST(LocalAudioSourceTest, InitWithAudioOptions) {
19 cricket::AudioOptions audio_options;
20 audio_options.highpass_filter = true;
21 rtc::scoped_refptr<LocalAudioSource> source =
22 LocalAudioSource::Create(&audio_options);
23 EXPECT_EQ(true, source->options().highpass_filter);
26 TEST(LocalAudioSourceTest, InitWithNoOptions) {
27 rtc::scoped_refptr<LocalAudioSource> source =
28 LocalAudioSource::Create(nullptr);
29 EXPECT_EQ(absl::nullopt, source->options().highpass_filter);