| 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 #import <Cocoa/Cocoa.h> | 5 #import <Cocoa/Cocoa.h> |
| 6 | 6 |
| 7 #include "base/sys_string_conversions.h" | 7 #include "base/sys_string_conversions.h" |
| 8 #include "chrome/browser/bookmarks/bookmark_model.h" |
| 8 #import "chrome/browser/cocoa/bookmark_editor_controller.h" | 9 #import "chrome/browser/cocoa/bookmark_editor_controller.h" |
| 9 #include "chrome/browser/cocoa/browser_test_helper.h" | 10 #include "chrome/browser/cocoa/browser_test_helper.h" |
| 10 #import "chrome/browser/cocoa/cocoa_test_helper.h" | 11 #import "chrome/browser/cocoa/cocoa_test_helper.h" |
| 11 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
| 12 #import "testing/gtest_mac.h" | 13 #import "testing/gtest_mac.h" |
| 13 #include "testing/platform_test.h" | 14 #include "testing/platform_test.h" |
| 14 | 15 |
| 15 class BookmarkEditorControllerTest : public CocoaTest { | 16 class BookmarkEditorControllerTest : public CocoaTest { |
| 16 public: | 17 public: |
| 17 BrowserTestHelper browser_helper_; | 18 BrowserTestHelper browser_helper_; |
| (...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 410 | 411 |
| 411 TEST_F(BookmarkEditorControllerTreeNoNodeTest, NewBookmarkNoNode) { | 412 TEST_F(BookmarkEditorControllerTreeNoNodeTest, NewBookmarkNoNode) { |
| 412 [controller_ setDisplayName:@"NEW BOOKMARK"]; | 413 [controller_ setDisplayName:@"NEW BOOKMARK"]; |
| 413 [controller_ setDisplayURL:@"http://NEWURL.com"]; | 414 [controller_ setDisplayURL:@"http://NEWURL.com"]; |
| 414 [controller_ ok:nil]; | 415 [controller_ ok:nil]; |
| 415 const BookmarkNode* new_node = group_bb_->GetChild(5); | 416 const BookmarkNode* new_node = group_bb_->GetChild(5); |
| 416 ASSERT_EQ(0, new_node->GetChildCount()); | 417 ASSERT_EQ(0, new_node->GetChildCount()); |
| 417 EXPECT_EQ(new_node->GetTitle(), L"NEW BOOKMARK"); | 418 EXPECT_EQ(new_node->GetTitle(), L"NEW BOOKMARK"); |
| 418 EXPECT_EQ(new_node->GetURL(), GURL("http://NEWURL.com")); | 419 EXPECT_EQ(new_node->GetURL(), GURL("http://NEWURL.com")); |
| 419 } | 420 } |
| OLD | NEW |