OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 "ios/chrome/browser/ui/content_suggestions/content_suggestions_expandabl
e_item.h" | 5 #import "ios/chrome/browser/ui/content_suggestions/cells/content_suggestions_exp
andable_item.h" |
6 | 6 |
7 #include "testing/gtest/include/gtest/gtest.h" | 7 #include "testing/gtest/include/gtest/gtest.h" |
8 #import "third_party/ocmock/OCMock/OCMock.h" | 8 #import "third_party/ocmock/OCMock/OCMock.h" |
9 #include "third_party/ocmock/gtest_support.h" | 9 #include "third_party/ocmock/gtest_support.h" |
10 | 10 |
11 #if !defined(__has_feature) || !__has_feature(objc_arc) | 11 #if !defined(__has_feature) || !__has_feature(objc_arc) |
12 #error "This file requires ARC support." | 12 #error "This file requires ARC support." |
13 #endif | 13 #endif |
14 | 14 |
15 // Test subclass of the ContentSuggestionsExpandableCell. | 15 // Test subclass of the ContentSuggestionsExpandableCell. |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 [[TestContentSuggestionsExpandableCell alloc] init]; | 99 [[TestContentSuggestionsExpandableCell alloc] init]; |
100 item.cellClass = [TestContentSuggestionsExpandableCell class]; | 100 item.cellClass = [TestContentSuggestionsExpandableCell class]; |
101 | 101 |
102 item.expanded = NO; | 102 item.expanded = NO; |
103 [item configureCell:cell]; | 103 [item configureCell:cell]; |
104 ASSERT_TRUE(cell.collapseCalled); | 104 ASSERT_TRUE(cell.collapseCalled); |
105 ASSERT_FALSE(cell.expandCalled); | 105 ASSERT_FALSE(cell.expandCalled); |
106 } | 106 } |
107 | 107 |
108 } // namespace | 108 } // namespace |
OLD | NEW |