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

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

Issue 10823050: Removing instances of profile_->GetBookmarkModel() as part of converting BookmarkModel to a PKS. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/applescript/bookmark_node_applescript.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #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 9
9 @implementation FakeAppDelegate 10 @implementation FakeAppDelegate
10 11
11 @synthesize test = test_; 12 @synthesize test = test_;
12 13
13 - (Profile*)lastProfile { 14 - (Profile*)lastProfile {
14 if (!test_) 15 if (!test_)
15 return NULL; 16 return NULL;
16 return test_->profile(); 17 return test_->profile();
17 } 18 }
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 DCHECK([NSApp delegate] == nil); 63 DCHECK([NSApp delegate] == nil);
63 [NSApp setDelegate:appDelegate_]; 64 [NSApp setDelegate:appDelegate_];
64 const BookmarkNode* root = model().bookmark_bar_node(); 65 const BookmarkNode* root = model().bookmark_bar_node();
65 const std::string modelString("a f1:[ b d c ] d f2:[ e f g ] h "); 66 const std::string modelString("a f1:[ b d c ] d f2:[ e f g ] h ");
66 model_test_utils::AddNodesFromModelString(model(), root, modelString); 67 model_test_utils::AddNodesFromModelString(model(), root, modelString);
67 bookmarkBar_.reset([[BookmarkFolderAppleScript alloc] 68 bookmarkBar_.reset([[BookmarkFolderAppleScript alloc]
68 initWithBookmarkNode:model().bookmark_bar_node()]); 69 initWithBookmarkNode:model().bookmark_bar_node()]);
69 } 70 }
70 71
71 BookmarkModel& BookmarkAppleScriptTest::model() { 72 BookmarkModel& BookmarkAppleScriptTest::model() {
72 return *profile()->GetBookmarkModel(); 73 return *BookmarkModelFactory::GetForProfile(profile());
73 } 74 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/applescript/bookmark_node_applescript.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698