| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/geolocation/gps_location_provider_linux.h" | 5 #include "content/browser/browser_thread.h" |
| 6 | 6 #include "content/browser/geolocation/gps_location_provider_linux.h" |
| 7 #include "chrome/browser/browser_thread.h" | 7 #include "content/browser/geolocation/libgps_wrapper_linux.h" |
| 8 #include "chrome/browser/geolocation/libgps_wrapper_linux.h" | |
| 9 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
| 10 | 9 |
| 11 struct gps_data_t { | 10 struct gps_data_t { |
| 12 }; | 11 }; |
| 13 | 12 |
| 14 namespace { | 13 namespace { |
| 15 class MockLibGps : public LibGps { | 14 class MockLibGps : public LibGps { |
| 16 public: | 15 public: |
| 17 MockLibGps(); | 16 MockLibGps(); |
| 18 ~MockLibGps(); | 17 ~MockLibGps(); |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 EXPECT_EQ(2, MockLibGps::g_instance_->get_position_calls_); | 185 EXPECT_EQ(2, MockLibGps::g_instance_->get_position_calls_); |
| 187 CheckValidPosition(MockLibGps::g_instance_->get_position_, position); | 186 CheckValidPosition(MockLibGps::g_instance_->get_position_, position); |
| 188 } | 187 } |
| 189 | 188 |
| 190 // TODO(joth): Add a test for LibGps::Start() returning false (i.e. gpsd not | 189 // TODO(joth): Add a test for LibGps::Start() returning false (i.e. gpsd not |
| 191 // running). Need to work around the 10s reconnect delay (either by injecting | 190 // running). Need to work around the 10s reconnect delay (either by injecting |
| 192 // a shorter retry interval, or adapt MessageLoop / Time::Now to be more test | 191 // a shorter retry interval, or adapt MessageLoop / Time::Now to be more test |
| 193 // friendly). | 192 // friendly). |
| 194 | 193 |
| 195 } // namespace | 194 } // namespace |
| OLD | NEW |