tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

mock_audio_sink.h (1346B)


      1 /*
      2 *  Copyright 2021 The WebRTC project authors. All Rights Reserved.
      3 *
      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 */
     10 
     11 #ifndef API_TEST_MOCK_AUDIO_SINK_H_
     12 #define API_TEST_MOCK_AUDIO_SINK_H_
     13 
     14 #include <cstddef>
     15 #include <cstdint>
     16 #include <optional>
     17 
     18 #include "api/media_stream_interface.h"
     19 #include "test/gmock.h"
     20 
     21 namespace webrtc {
     22 
     23 class MockAudioSink : public AudioTrackSinkInterface {
     24 public:
     25  MOCK_METHOD(void,
     26              OnData,
     27              (const void* audio_data,
     28               int bits_per_sample,
     29               int sample_rate,
     30               size_t number_of_channels,
     31               size_t number_of_frames),
     32              (override));
     33 
     34  MOCK_METHOD(void,
     35              OnData,
     36              (const void* audio_data,
     37               int bits_per_sample,
     38               int sample_rate,
     39               size_t number_of_channels,
     40               size_t number_of_frames,
     41               std::optional<int64_t> absolute_capture_timestamp_ms),
     42              (override));
     43 };
     44 
     45 }  // namespace webrtc
     46 
     47 #endif  // API_TEST_MOCK_AUDIO_SINK_H_