mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-08-25 13:07:02 +00:00
32 lines
831 B
Plaintext
32 lines
831 B
Plaintext
// Just doing @import <AppKit/CPCollectionView.j> failed on CPWindow not being defined somewhere.
|
|
@import <AppKit/AppKit.j>
|
|
|
|
@implementation CPCollectionViewTest : OJTestCase
|
|
{
|
|
CPCollectionView _collectionView;
|
|
}
|
|
|
|
- (void)setUp
|
|
{
|
|
_collectionView = [[CPCollectionView alloc] initWithFrame:CGRectMakeZero()];
|
|
}
|
|
|
|
- (void)testItemPrototypeActuallyReturnsTheItemPrototype
|
|
{
|
|
var itemPrototype = [[CPCollectionViewItem alloc] init];
|
|
[_collectionView setItemPrototype:itemPrototype];
|
|
|
|
[self assert:itemPrototype same:[_collectionView itemPrototype]];
|
|
}
|
|
|
|
- (void)testIsSelectableActuallyReturnsSelectableStatus
|
|
{
|
|
[_collectionView setSelectable:YES];
|
|
[self assertTrue:[_collectionView isSelectable]];
|
|
|
|
[_collectionView setSelectable:NO];
|
|
[self assertFalse:[_collectionView isSelectable]];
|
|
}
|
|
|
|
@end
|