OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <string> | 5 #include <string> |
6 | 6 |
7 #include "chrome/browser/extensions/extension_service.h" | 7 #include "chrome/browser/extensions/extension_service.h" |
8 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
9 #include "chrome/browser/ui/browser.h" | 9 #include "chrome/browser/ui/browser.h" |
10 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 10 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
(...skipping 26 matching lines...) Expand all Loading... |
37 private: | 37 private: |
38 // content::NotificationObserver | 38 // content::NotificationObserver |
39 virtual void Observe(int type, | 39 virtual void Observe(int type, |
40 const content::NotificationSource& source, | 40 const content::NotificationSource& source, |
41 const content::NotificationDetails& details) OVERRIDE { | 41 const content::NotificationDetails& details) OVERRIDE { |
42 if (type == chrome::NOTIFICATION_EXTENSION_INSTALLED) { | 42 if (type == chrome::NOTIFICATION_EXTENSION_INSTALLED) { |
43 const Extension* extension = | 43 const Extension* extension = |
44 content::Details<const InstalledExtensionInfo>(details)->extension; | 44 content::Details<const InstalledExtensionInfo>(details)->extension; |
45 if (extension->id() == expected_extension_id_) { | 45 if (extension->id() == expected_extension_id_) { |
46 installed_extension_ = extension; | 46 installed_extension_ = extension; |
47 MessageLoopForUI::current()->Quit(); | 47 base::MessageLoopForUI::current()->Quit(); |
48 } | 48 } |
49 } | 49 } |
50 } | 50 } |
51 }; | 51 }; |
52 | 52 |
53 #if defined(OS_CHROMEOS) | 53 #if defined(OS_CHROMEOS) |
54 // The Apps tab is not included in the new tab page in Chrome OS. | 54 // The Apps tab is not included in the new tab page in Chrome OS. |
55 #define MAYBE_Basic DISABLED_Basic | 55 #define MAYBE_Basic DISABLED_Basic |
56 #else | 56 #else |
57 #define MAYBE_Basic Basic | 57 #define MAYBE_Basic Basic |
(...skipping 24 matching lines...) Expand all Loading... |
82 EXPECT_EQ("Test application", installed_extension_->name()); | 82 EXPECT_EQ("Test application", installed_extension_->name()); |
83 EXPECT_EQ("", installed_extension_->description()); | 83 EXPECT_EQ("", installed_extension_->description()); |
84 EXPECT_EQ("http://www.example.com/", installed_extension_->launch_web_url()); | 84 EXPECT_EQ("http://www.example.com/", installed_extension_->launch_web_url()); |
85 EXPECT_EQ(extension_misc::LAUNCH_TAB, | 85 EXPECT_EQ(extension_misc::LAUNCH_TAB, |
86 installed_extension_->launch_container()); | 86 installed_extension_->launch_container()); |
87 EXPECT_EQ(0u, installed_extension_->GetActivePermissions()->apis().size()); | 87 EXPECT_EQ(0u, installed_extension_->GetActivePermissions()->apis().size()); |
88 EXPECT_EQ(0u, IconsInfo::GetIcons(installed_extension_).map().size()); | 88 EXPECT_EQ(0u, IconsInfo::GetIcons(installed_extension_).map().size()); |
89 } | 89 } |
90 | 90 |
91 } // namespace extensions | 91 } // namespace extensions |
OLD | NEW |