OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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/chromeos/note_taking_helper.h" | 5 #include "chrome/browser/chromeos/note_taking_helper.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "ash/ash_switches.h" | 9 #include "ash/ash_switches.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
253 Profile* profile) { | 253 Profile* profile) { |
254 extensions::ExtensionSystem::Get(profile) | 254 extensions::ExtensionSystem::Get(profile) |
255 ->extension_service() | 255 ->extension_service() |
256 ->AddExtension(extension); | 256 ->AddExtension(extension); |
257 } | 257 } |
258 void UninstallExtension(const extensions::Extension* extension, | 258 void UninstallExtension(const extensions::Extension* extension, |
259 Profile* profile) { | 259 Profile* profile) { |
260 extensions::ExtensionSystem::Get(profile) | 260 extensions::ExtensionSystem::Get(profile) |
261 ->extension_service() | 261 ->extension_service() |
262 ->UnloadExtension(extension->id(), | 262 ->UnloadExtension(extension->id(), |
263 extensions::UnloadedExtensionInfo::REASON_UNINSTALL); | 263 extensions::UnloadedExtensionReason::UNINSTALL); |
264 } | 264 } |
265 | 265 |
266 // BrowserWithTestWindowTest: | 266 // BrowserWithTestWindowTest: |
267 TestingProfile* CreateProfile() override { | 267 TestingProfile* CreateProfile() override { |
268 // Ensure that the profile created by BrowserWithTestWindowTest is | 268 // Ensure that the profile created by BrowserWithTestWindowTest is |
269 // registered with |profile_manager_|. | 269 // registered with |profile_manager_|. |
270 return profile_manager_->CreateTestingProfile(kTestProfileName); | 270 return profile_manager_->CreateTestingProfile(kTestProfileName); |
271 } | 271 } |
272 void DestroyProfile(TestingProfile* profile) override { | 272 void DestroyProfile(TestingProfile* profile) override { |
273 return profile_manager_->DeleteTestingProfile(kTestProfileName); | 273 return profile_manager_->DeleteTestingProfile(kTestProfileName); |
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
749 InitExtensionService(second_profile); | 749 InitExtensionService(second_profile); |
750 EXPECT_EQ(0, observer.num_updates()); | 750 EXPECT_EQ(0, observer.num_updates()); |
751 InstallExtension(keep_extension.get(), second_profile); | 751 InstallExtension(keep_extension.get(), second_profile); |
752 EXPECT_EQ(1, observer.num_updates()); | 752 EXPECT_EQ(1, observer.num_updates()); |
753 UninstallExtension(keep_extension.get(), second_profile); | 753 UninstallExtension(keep_extension.get(), second_profile); |
754 EXPECT_EQ(2, observer.num_updates()); | 754 EXPECT_EQ(2, observer.num_updates()); |
755 profile_manager_->DeleteTestingProfile(kSecondProfileName); | 755 profile_manager_->DeleteTestingProfile(kSecondProfileName); |
756 } | 756 } |
757 | 757 |
758 } // namespace chromeos | 758 } // namespace chromeos |
OLD | NEW |