| OLD | NEW |
| 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 #include "chrome/browser/bookmarks/bookmark_model.h" | 5 #include "chrome/browser/bookmarks/bookmark_model.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/base_paths.h" | 10 #include "base/base_paths.h" |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 int index1_; | 143 int index1_; |
| 144 int index2_; | 144 int index2_; |
| 145 }; | 145 }; |
| 146 | 146 |
| 147 BookmarkModelTest() | 147 BookmarkModelTest() |
| 148 : model_(NULL) { | 148 : model_(NULL) { |
| 149 model_.AddObserver(this); | 149 model_.AddObserver(this); |
| 150 ClearCounts(); | 150 ClearCounts(); |
| 151 } | 151 } |
| 152 | 152 |
| 153 void Loaded(BookmarkModel* model, bool ids_reassigned) OVERRIDE { | 153 virtual void Loaded(BookmarkModel* model, bool ids_reassigned) OVERRIDE { |
| 154 // We never load from the db, so that this should never get invoked. | 154 // We never load from the db, so that this should never get invoked. |
| 155 NOTREACHED(); | 155 NOTREACHED(); |
| 156 } | 156 } |
| 157 | 157 |
| 158 virtual void BookmarkNodeMoved(BookmarkModel* model, | 158 virtual void BookmarkNodeMoved(BookmarkModel* model, |
| 159 const BookmarkNode* old_parent, | 159 const BookmarkNode* old_parent, |
| 160 int old_index, | 160 int old_index, |
| 161 const BookmarkNode* new_parent, | 161 const BookmarkNode* new_parent, |
| 162 int new_index) OVERRIDE { | 162 int new_index) OVERRIDE { |
| 163 ++moved_count_; | 163 ++moved_count_; |
| (...skipping 886 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1050 | 1050 |
| 1051 EXPECT_TRUE(node.DeleteMetaInfo("key1")); | 1051 EXPECT_TRUE(node.DeleteMetaInfo("key1")); |
| 1052 EXPECT_TRUE(node.DeleteMetaInfo("key2")); | 1052 EXPECT_TRUE(node.DeleteMetaInfo("key2")); |
| 1053 EXPECT_FALSE(node.DeleteMetaInfo("key3")); | 1053 EXPECT_FALSE(node.DeleteMetaInfo("key3")); |
| 1054 EXPECT_FALSE(node.GetMetaInfo("key1", &out_value)); | 1054 EXPECT_FALSE(node.GetMetaInfo("key1", &out_value)); |
| 1055 EXPECT_FALSE(node.GetMetaInfo("key2", &out_value)); | 1055 EXPECT_FALSE(node.GetMetaInfo("key2", &out_value)); |
| 1056 EXPECT_TRUE(node.meta_info_str().empty()); | 1056 EXPECT_TRUE(node.meta_info_str().empty()); |
| 1057 } | 1057 } |
| 1058 | 1058 |
| 1059 } // namespace | 1059 } // namespace |
| OLD | NEW |