Scroll in Android HTML Element accessibility navigation
[chromium-blink-merge.git] / chromecast / net / fake_connectivity_checker.h
blob7381b8f0ddcfc668b6e31b8fd945730c55c8c5cf
1 // Copyright 2015 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.
5 #include "chromecast/net/connectivity_checker.h"
7 namespace chromecast {
9 // A simple fake connectivity checker for testing. Will appeared to be
10 // connected by default.
11 class FakeConnectivityChecker : public ConnectivityChecker {
12 public:
13 FakeConnectivityChecker();
15 // ConnectivityChecker implementation:
16 bool Connected() const override;
17 void Check() override;
19 // Sets connectivity and notifies observers if it has changed.
20 void SetConnectedForTest(bool connected);
22 protected:
23 ~FakeConnectivityChecker() override;
25 private:
26 friend class base::RefCountedThreadSafe<FakeConnectivityChecker>;
27 bool connected_;
29 DISALLOW_COPY_AND_ASSIGN(FakeConnectivityChecker);
32 } // namespace chromecast