mock_devices_changed_observer.h 846 B

12345678910111213141516171819202122232425262728293031
  1. // Copyright (c) 2012 The Chromium 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. #ifndef BASE_TEST_MOCK_DEVICES_CHANGED_OBSERVER_H_
  5. #define BASE_TEST_MOCK_DEVICES_CHANGED_OBSERVER_H_
  6. #include <string>
  7. #include "base/macros.h"
  8. #include "base/system/system_monitor.h"
  9. #include "testing/gmock/include/gmock/gmock.h"
  10. namespace base {
  11. class MockDevicesChangedObserver
  12. : public base::SystemMonitor::DevicesChangedObserver {
  13. public:
  14. MockDevicesChangedObserver();
  15. ~MockDevicesChangedObserver() override;
  16. MOCK_METHOD1(OnDevicesChanged,
  17. void(base::SystemMonitor::DeviceType device_type));
  18. private:
  19. DISALLOW_COPY_AND_ASSIGN(MockDevicesChangedObserver);
  20. };
  21. } // namespace base
  22. #endif // BASE_TEST_MOCK_DEVICES_CHANGED_OBSERVER_H_