simple_geolocation_request_test_monitor.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. // Copyright 2016 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 ASH_COMPONENTS_GEOLOCATION_SIMPLE_GEOLOCATION_REQUEST_TEST_MONITOR_H_
  5. #define ASH_COMPONENTS_GEOLOCATION_SIMPLE_GEOLOCATION_REQUEST_TEST_MONITOR_H_
  6. #include "base/component_export.h"
  7. namespace ash {
  8. class SimpleGeolocationRequest;
  9. // This is global hook, that allows to monitor SimpleGeolocationRequest
  10. // in tests.
  11. //
  12. // Note: we need COMPONENT_EXPORT(ASH_GEOLOCATION) for tests.
  13. class COMPONENT_EXPORT(ASH_GEOLOCATION)
  14. SimpleGeolocationRequestTestMonitor {
  15. public:
  16. SimpleGeolocationRequestTestMonitor();
  17. SimpleGeolocationRequestTestMonitor(
  18. const SimpleGeolocationRequestTestMonitor&) = delete;
  19. SimpleGeolocationRequestTestMonitor& operator=(
  20. const SimpleGeolocationRequestTestMonitor&) = delete;
  21. virtual ~SimpleGeolocationRequestTestMonitor();
  22. virtual void OnRequestCreated(SimpleGeolocationRequest* request);
  23. virtual void OnStart(SimpleGeolocationRequest* request);
  24. };
  25. } // namespace ash
  26. #endif // ASH_COMPONENTS_GEOLOCATION_SIMPLE_GEOLOCATION_REQUEST_TEST_MONITOR_H_