OLD | NEW |
---|---|
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/browser.h" | |
6 #include "chrome/browser/extensions/extension_browsertest.h" | 5 #include "chrome/browser/extensions/extension_browsertest.h" |
6 #include "chrome/browser/extensions/extensions_service.h" | |
Lei Zhang
2010/11/16 20:01:28
ordering
James Hawkins
2010/11/16 20:43:29
The ordering is correct. Strip out all punctuation
| |
7 #include "chrome/browser/extensions/extension_toolbar_model.h" | 7 #include "chrome/browser/extensions/extension_toolbar_model.h" |
8 #include "chrome/browser/extensions/extensions_service.h" | |
9 #include "chrome/browser/profile.h" | 8 #include "chrome/browser/profile.h" |
9 #include "chrome/browser/ui/browser.h" | |
10 #include "chrome/common/chrome_switches.h" | 10 #include "chrome/common/chrome_switches.h" |
11 #include "chrome/test/in_process_browser_test.h" | 11 #include "chrome/test/in_process_browser_test.h" |
12 | 12 |
13 // An InProcessBrowserTest for testing the ExtensionToolbarModel. | 13 // An InProcessBrowserTest for testing the ExtensionToolbarModel. |
14 // TODO(erikkay) It's unfortunate that this needs to be an in-proc browser test. | 14 // TODO(erikkay) It's unfortunate that this needs to be an in-proc browser test. |
15 // It would be nice to refactor things so that ExtensionsService could run | 15 // It would be nice to refactor things so that ExtensionsService could run |
16 // without so much of the browser in place. | 16 // without so much of the browser in place. |
17 class ExtensionToolbarModelTest : public ExtensionBrowserTest, | 17 class ExtensionToolbarModelTest : public ExtensionBrowserTest, |
18 public ExtensionToolbarModel::Observer { | 18 public ExtensionToolbarModel::Observer { |
19 public: | 19 public: |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
221 | 221 |
222 // Load extension C again. | 222 // Load extension C again. |
223 ASSERT_TRUE(LoadExtension(extension_c_path)); | 223 ASSERT_TRUE(LoadExtension(extension_c_path)); |
224 | 224 |
225 // Extension C loaded again. | 225 // Extension C loaded again. |
226 EXPECT_EQ(5, inserted_count_); | 226 EXPECT_EQ(5, inserted_count_); |
227 EXPECT_EQ(2u, model_->size()); | 227 EXPECT_EQ(2u, model_->size()); |
228 // Make sure it gets its old spot in the list (at the very end). | 228 // Make sure it gets its old spot in the list (at the very end). |
229 ASSERT_STREQ(idC.c_str(), ExtensionAt(1)->id().c_str()); | 229 ASSERT_STREQ(idC.c_str(), ExtensionAt(1)->id().c_str()); |
230 } | 230 } |
OLD | NEW |