terelius | 429c345 | 2016-01-21 05:42:04 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2016 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 WEBRTC_CALL_MOCK_MOCK_RTC_EVENT_LOG_H_ |
| 12 | #define WEBRTC_CALL_MOCK_MOCK_RTC_EVENT_LOG_H_ |
| 13 | |
| 14 | #include <string> |
| 15 | |
| 16 | #include "testing/gmock/include/gmock/gmock.h" |
| 17 | |
| 18 | #include "webrtc/call/rtc_event_log.h" |
| 19 | |
| 20 | namespace webrtc { |
| 21 | |
| 22 | class MockRtcEventLog : public RtcEventLog { |
| 23 | public: |
terelius | 4311ba5 | 2016-04-22 12:40:37 -0700 | [diff] [blame] | 24 | MOCK_METHOD2(StartLogging, |
| 25 | bool(const std::string& file_name, int64_t max_size_bytes)); |
terelius | 429c345 | 2016-01-21 05:42:04 -0800 | [diff] [blame] | 26 | |
| 27 | MOCK_METHOD2(StartLogging, |
terelius | 4311ba5 | 2016-04-22 12:40:37 -0700 | [diff] [blame] | 28 | bool(rtc::PlatformFile log_file, int64_t max_size_bytes)); |
terelius | 429c345 | 2016-01-21 05:42:04 -0800 | [diff] [blame] | 29 | |
| 30 | MOCK_METHOD0(StopLogging, void()); |
| 31 | |
| 32 | MOCK_METHOD1(LogVideoReceiveStreamConfig, |
| 33 | void(const webrtc::VideoReceiveStream::Config& config)); |
| 34 | |
| 35 | MOCK_METHOD1(LogVideoSendStreamConfig, |
| 36 | void(const webrtc::VideoSendStream::Config& config)); |
| 37 | |
| 38 | MOCK_METHOD4(LogRtpHeader, |
| 39 | void(PacketDirection direction, |
| 40 | MediaType media_type, |
| 41 | const uint8_t* header, |
| 42 | size_t packet_length)); |
| 43 | |
| 44 | MOCK_METHOD4(LogRtcpPacket, |
| 45 | void(PacketDirection direction, |
| 46 | MediaType media_type, |
| 47 | const uint8_t* packet, |
| 48 | size_t length)); |
| 49 | |
| 50 | MOCK_METHOD1(LogAudioPlayout, void(uint32_t ssrc)); |
| 51 | |
| 52 | MOCK_METHOD3(LogBwePacketLossEvent, |
| 53 | void(int32_t bitrate, |
| 54 | uint8_t fraction_loss, |
| 55 | int32_t total_packets)); |
| 56 | }; |
| 57 | |
| 58 | } // namespace webrtc |
| 59 | |
| 60 | #endif // WEBRTC_CALL_MOCK_MOCK_RTC_EVENT_LOG_H_ |