| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/ui/panels/base_panel_browser_test.h" | 5 #include "chrome/browser/ui/panels/base_panel_browser_test.h" |
| 6 | 6 |
| 7 #include "chrome/browser/ui/browser_list.h" | 7 #include "chrome/browser/ui/browser_list.h" |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
| 12 #include "base/message_loop.h" | 12 #include "base/message_loop.h" |
| 13 #include "base/path_service.h" | 13 #include "base/path_service.h" |
| 14 #include "chrome/browser/extensions/extension_service.h" | 14 #include "chrome/browser/extensions/extension_service.h" |
| 15 #include "chrome/browser/profiles/profile.h" | 15 #include "chrome/browser/profiles/profile.h" |
| 16 #include "chrome/browser/ui/browser.h" | 16 #include "chrome/browser/ui/browser.h" |
| 17 #include "chrome/browser/ui/panels/native_panel.h" | 17 #include "chrome/browser/ui/panels/native_panel.h" |
| 18 #include "chrome/browser/ui/panels/panel_manager.h" | 18 #include "chrome/browser/ui/panels/panel_manager.h" |
| 19 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" | 19 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
| 20 #include "chrome/common/chrome_paths.h" | 20 #include "chrome/common/chrome_paths.h" |
| 21 #include "chrome/common/chrome_switches.h" | 21 #include "chrome/common/chrome_switches.h" |
| 22 #include "chrome/common/string_ordinal.h" |
| 22 #include "chrome/test/base/ui_test_utils.h" | 23 #include "chrome/test/base/ui_test_utils.h" |
| 23 #include "content/browser/tab_contents/test_tab_contents.h" | 24 #include "content/browser/tab_contents/test_tab_contents.h" |
| 24 #include "content/public/browser/notification_service.h" | 25 #include "content/public/browser/notification_service.h" |
| 25 #include "content/public/common/url_constants.h" | 26 #include "content/public/common/url_constants.h" |
| 26 | 27 |
| 27 #if defined(OS_MACOSX) | 28 #if defined(OS_MACOSX) |
| 28 #include "base/mac/scoped_nsautorelease_pool.h" | 29 #include "base/mac/scoped_nsautorelease_pool.h" |
| 29 #include "chrome/browser/ui/cocoa/find_bar/find_bar_bridge.h" | 30 #include "chrome/browser/ui/cocoa/find_bar/find_bar_bridge.h" |
| 30 #endif | 31 #endif |
| 31 | 32 |
| (...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 353 input_value->SetString(extension_manifest_keys::kVersion, "1.0.0.0"); | 354 input_value->SetString(extension_manifest_keys::kVersion, "1.0.0.0"); |
| 354 input_value->SetString(extension_manifest_keys::kName, "Sample Extension"); | 355 input_value->SetString(extension_manifest_keys::kName, "Sample Extension"); |
| 355 | 356 |
| 356 std::string error; | 357 std::string error; |
| 357 scoped_refptr<Extension> extension = Extension::Create( | 358 scoped_refptr<Extension> extension = Extension::Create( |
| 358 full_path, location, *input_value, | 359 full_path, location, *input_value, |
| 359 Extension::STRICT_ERROR_CHECKS, &error); | 360 Extension::STRICT_ERROR_CHECKS, &error); |
| 360 EXPECT_TRUE(extension.get()); | 361 EXPECT_TRUE(extension.get()); |
| 361 EXPECT_STREQ("", error.c_str()); | 362 EXPECT_STREQ("", error.c_str()); |
| 362 browser()->GetProfile()->GetExtensionService()-> | 363 browser()->GetProfile()->GetExtensionService()-> |
| 363 OnExtensionInstalled(extension.get(), false, -1); | 364 OnExtensionInstalled(extension.get(), false, StringOrdinal()); |
| 364 return extension; | 365 return extension; |
| 365 } | 366 } |
| OLD | NEW |