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 <string> | 5 #include <string> |
6 #include <vector> | 6 #include <vector> |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 model_ = profile_->GetBookmarkModel(); | 69 model_ = profile_->GetBookmarkModel(); |
70 | 70 |
71 AddTestData(); | 71 AddTestData(); |
72 } | 72 } |
73 | 73 |
74 virtual void TearDown() { | 74 virtual void TearDown() { |
75 #if defined(OS_WIN) | 75 #if defined(OS_WIN) |
76 BookmarkBarView::testing_ = false; | 76 BookmarkBarView::testing_ = false; |
77 #endif | 77 #endif |
78 | 78 |
79 // Flush the message loop to make Purify happy. | 79 // Flush the message loop to make application verifiers happy. |
80 message_loop_.RunAllPending(); | 80 message_loop_.RunAllPending(); |
81 } | 81 } |
82 | 82 |
83 protected: | 83 protected: |
84 MessageLoopForUI message_loop_; | 84 MessageLoopForUI message_loop_; |
85 BrowserThread ui_thread_; | 85 BrowserThread ui_thread_; |
86 BrowserThread file_thread_; | 86 BrowserThread file_thread_; |
87 scoped_ptr<TestingProfile> profile_; | 87 scoped_ptr<TestingProfile> profile_; |
88 BookmarkModel* model_; | 88 BookmarkModel* model_; |
89 TestingPageNavigator navigator_; | 89 TestingPageNavigator navigator_; |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
313 ASSERT_EQ(bb_node->GetChild(0)->url(), bb_node->GetChild(1)->url()); | 313 ASSERT_EQ(bb_node->GetChild(0)->url(), bb_node->GetChild(1)->url()); |
314 | 314 |
315 controller.reset(new BookmarkContextMenu( | 315 controller.reset(new BookmarkContextMenu( |
316 NULL, profile_.get(), NULL, nodes[0]->parent(), nodes, false)); | 316 NULL, profile_.get(), NULL, nodes[0]->parent(), nodes, false)); |
317 // Cut the URL. | 317 // Cut the URL. |
318 controller->ExecuteCommand(IDC_CUT); | 318 controller->ExecuteCommand(IDC_CUT); |
319 ASSERT_TRUE(bb_node->GetChild(0)->is_url()); | 319 ASSERT_TRUE(bb_node->GetChild(0)->is_url()); |
320 ASSERT_TRUE(bb_node->GetChild(1)->is_folder()); | 320 ASSERT_TRUE(bb_node->GetChild(1)->is_folder()); |
321 ASSERT_EQ(old_count, bb_node->child_count()); | 321 ASSERT_EQ(old_count, bb_node->child_count()); |
322 } | 322 } |
OLD | NEW |