Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(58)

Side by Side Diff: chrome/browser/ui/cocoa/applescript/bookmark_applescript_utils_unittest.mm

Issue 23570009: bookmarks: Cleanup, remove BookmarkModelTestUtils class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #import "chrome/browser/ui/cocoa/applescript/bookmark_applescript_utils_unittest .h" 5 #import "chrome/browser/ui/cocoa/applescript/bookmark_applescript_utils_unittest .h"
6 6
7 #include "chrome/browser/bookmarks/bookmark_model.h" 7 #include "chrome/browser/bookmarks/bookmark_model.h"
8 #include "chrome/browser/bookmarks/bookmark_model_factory.h" 8 #include "chrome/browser/bookmarks/bookmark_model_factory.h"
9 #include "chrome/browser/bookmarks/bookmark_model_test_utils.h" 9 #include "chrome/browser/bookmarks/bookmark_test_helpers.h"
10 10
11 @implementation FakeAppDelegate 11 @implementation FakeAppDelegate
12 12
13 @synthesize test = test_; 13 @synthesize test = test_;
14 14
15 - (Profile*)lastProfile { 15 - (Profile*)lastProfile {
16 if (!test_) 16 if (!test_)
17 return NULL; 17 return NULL;
18 return test_->profile(); 18 return test_->profile();
19 } 19 }
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 CocoaProfileTest::SetUp(); 59 CocoaProfileTest::SetUp();
60 ASSERT_TRUE(profile()); 60 ASSERT_TRUE(profile());
61 61
62 appDelegate_.reset([[FakeAppDelegate alloc] init]); 62 appDelegate_.reset([[FakeAppDelegate alloc] init]);
63 [appDelegate_.get() setTest:this]; 63 [appDelegate_.get() setTest:this];
64 DCHECK([NSApp delegate] == nil); 64 DCHECK([NSApp delegate] == nil);
65 [NSApp setDelegate:appDelegate_]; 65 [NSApp setDelegate:appDelegate_];
66 BookmarkModel* model = BookmarkModelFactory::GetForProfile(profile()); 66 BookmarkModel* model = BookmarkModelFactory::GetForProfile(profile());
67 const BookmarkNode* root = model->bookmark_bar_node(); 67 const BookmarkNode* root = model->bookmark_bar_node();
68 const std::string modelString("a f1:[ b d c ] d f2:[ e f g ] h "); 68 const std::string modelString("a f1:[ b d c ] d f2:[ e f g ] h ");
69 BookmarkModelTestUtils::AddNodesFromModelString(model, root, modelString); 69 test::AddNodesFromModelString(model, root, modelString);
70 bookmarkBar_.reset([[BookmarkFolderAppleScript alloc] 70 bookmarkBar_.reset([[BookmarkFolderAppleScript alloc]
71 initWithBookmarkNode:model->bookmark_bar_node()]); 71 initWithBookmarkNode:model->bookmark_bar_node()]);
72 } 72 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698