Samuel Tan | f66080e | 2015-06-18 15:53:00 -0700 | [diff] [blame] | 1 | // Copyright 2015 The Chromium OS Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #ifndef SHILL_MOCK_ICMP_H_ |
| 6 | #define SHILL_MOCK_ICMP_H_ |
| 7 | |
| 8 | #include "shill/icmp.h" |
| 9 | |
| 10 | #include <gmock/gmock.h> |
| 11 | |
| 12 | #include "shill/net/ip_address.h" |
| 13 | |
| 14 | namespace shill { |
| 15 | |
| 16 | class MockIcmp : public Icmp { |
| 17 | public: |
| 18 | MockIcmp(); |
| 19 | ~MockIcmp() override; |
| 20 | |
| 21 | MOCK_METHOD0(Start, bool()); |
| 22 | MOCK_METHOD0(Stop, void()); |
| 23 | MOCK_CONST_METHOD0(IsStarted, bool()); |
| 24 | MOCK_METHOD3(TransmitEchoRequest, bool(const IPAddress& destination, |
| 25 | uint16_t id, uint16_t seq_num)); |
| 26 | |
| 27 | private: |
| 28 | DISALLOW_COPY_AND_ASSIGN(MockIcmp); |
| 29 | }; |
| 30 | |
| 31 | } // namespace shill |
| 32 | |
| 33 | #endif // SHILL_MOCK_ICMP_H_ |