OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "base/command_line.h" | 5 #include "base/command_line.h" |
6 #include "base/prefs/pref_service.h" | 6 #include "base/prefs/pref_service.h" |
7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
8 #include "chrome/browser/extensions/activity_log/activity_log.h" | 8 #include "chrome/browser/extensions/activity_log/activity_log.h" |
9 #include "chrome/browser/extensions/api/activity_log_private/activity_log_privat
e_api.h" | 9 #include "chrome/browser/extensions/api/activity_log_private/activity_log_privat
e_api.h" |
10 #include "chrome/browser/extensions/extension_service.h" | 10 #include "chrome/browser/extensions/extension_service.h" |
11 #include "chrome/browser/extensions/test_extension_system.h" | 11 #include "chrome/browser/extensions/test_extension_system.h" |
12 #include "chrome/common/chrome_switches.h" | 12 #include "chrome/common/chrome_switches.h" |
13 #include "chrome/common/pref_names.h" | 13 #include "chrome/common/pref_names.h" |
14 #include "chrome/test/base/chrome_render_view_host_test_harness.h" | 14 #include "chrome/test/base/chrome_render_view_host_test_harness.h" |
15 #include "chrome/test/base/testing_profile.h" | 15 #include "chrome/test/base/testing_profile.h" |
16 #include "extensions/browser/uninstall_reason.h" | 16 #include "extensions/browser/uninstall_reason.h" |
17 #include "extensions/common/extension_builder.h" | 17 #include "extensions/common/extension_builder.h" |
18 | 18 |
19 #if defined OS_CHROMEOS | 19 #if defined OS_CHROMEOS |
20 #include "chrome/browser/chromeos/login/users/user_manager.h" | 20 #include "chrome/browser/chromeos/login/users/scoped_test_user_manager.h" |
21 #include "chrome/browser/chromeos/settings/cros_settings.h" | 21 #include "chrome/browser/chromeos/settings/cros_settings.h" |
22 #include "chrome/browser/chromeos/settings/device_settings_service.h" | 22 #include "chrome/browser/chromeos/settings/device_settings_service.h" |
23 #endif | 23 #endif |
24 | 24 |
25 namespace extensions { | 25 namespace extensions { |
26 | 26 |
27 const char* kExtensionID = "abjoigjokfeibfhiahiijggogladbmfm"; | 27 const char* kExtensionID = "abjoigjokfeibfhiahiijggogladbmfm"; |
28 | 28 |
29 class ActivityLogEnabledTest : public ChromeRenderViewHostTestHarness { | 29 class ActivityLogEnabledTest : public ChromeRenderViewHostTestHarness { |
30 protected: | 30 protected: |
(...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
277 EXPECT_TRUE(activity_log->IsDatabaseEnabled()); | 277 EXPECT_TRUE(activity_log->IsDatabaseEnabled()); |
278 EXPECT_EQ(0, | 278 EXPECT_EQ(0, |
279 profile->GetPrefs()->GetInteger(prefs::kWatchdogExtensionActive)); | 279 profile->GetPrefs()->GetInteger(prefs::kWatchdogExtensionActive)); |
280 EXPECT_FALSE(activity_log->IsWatchdogAppActive()); | 280 EXPECT_FALSE(activity_log->IsWatchdogAppActive()); |
281 | 281 |
282 // Cleanup. | 282 // Cleanup. |
283 *CommandLine::ForCurrentProcess() = saved_cmdline_; | 283 *CommandLine::ForCurrentProcess() = saved_cmdline_; |
284 } | 284 } |
285 | 285 |
286 } // namespace extensions | 286 } // namespace extensions |
OLD | NEW |