| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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/android/data_usage/data_use_matcher.h" | 5 #include "chrome/browser/android/data_usage/data_use_matcher.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 base::TimeTicks now_ticks_; | 57 base::TimeTicks now_ticks_; |
| 58 | 58 |
| 59 DISALLOW_COPY_AND_ASSIGN(NowTestTickClock); | 59 DISALLOW_COPY_AND_ASSIGN(NowTestTickClock); |
| 60 }; | 60 }; |
| 61 | 61 |
| 62 class TestExternalDataUseObserverBridge | 62 class TestExternalDataUseObserverBridge |
| 63 : public chrome::android::ExternalDataUseObserverBridge { | 63 : public chrome::android::ExternalDataUseObserverBridge { |
| 64 public: | 64 public: |
| 65 TestExternalDataUseObserverBridge() {} | 65 TestExternalDataUseObserverBridge() {} |
| 66 void FetchMatchingRules() const override {} | 66 void FetchMatchingRules() const override {} |
| 67 void ShouldRegisterAsDataUseObserver(bool should_register) const override{}; | 67 void ShouldRegisterAsDataUseObserver(bool should_register) const override {} |
| 68 }; | 68 }; |
| 69 | 69 |
| 70 } // namespace | 70 } // namespace |
| 71 | 71 |
| 72 namespace chrome { | 72 namespace chrome { |
| 73 | 73 |
| 74 namespace android { | 74 namespace android { |
| 75 | 75 |
| 76 class ExternalDataUseObserver; | 76 class ExternalDataUseObserver; |
| 77 | 77 |
| (...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 549 base::TimeDelta::FromMilliseconds(10001)); | 549 base::TimeDelta::FromMilliseconds(10001)); |
| 550 | 550 |
| 551 EXPECT_TRUE(IsExpired(0)); | 551 EXPECT_TRUE(IsExpired(0)); |
| 552 EXPECT_FALSE(data_use_matcher()->MatchesURL(GURL(kRegexFoo), &got_label)); | 552 EXPECT_FALSE(data_use_matcher()->MatchesURL(GURL(kRegexFoo), &got_label)); |
| 553 EXPECT_FALSE(data_use_matcher()->MatchesAppPackageName(kAppFoo, &got_label)); | 553 EXPECT_FALSE(data_use_matcher()->MatchesAppPackageName(kAppFoo, &got_label)); |
| 554 } | 554 } |
| 555 | 555 |
| 556 } // namespace android | 556 } // namespace android |
| 557 | 557 |
| 558 } // namespace chrome | 558 } // namespace chrome |
| OLD | NEW |