Skip to content

Commit

Permalink
added 2 tests for custom button with actionBlock
Browse files Browse the repository at this point in the history
  • Loading branch information
skywinder committed Oct 22, 2014
1 parent f176272 commit ab80aff
Showing 1 changed file with 21 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,5 +74,26 @@ - (void)testCustomFontNameWithAttributedTextAndTextAttributes
XCTAssertNotNil(_sheetStringPicker);
}

- (void)testPickerWithCustomActionBlockOnButton
{
NSString *title = @"Custom label:";

[_sheetStringPicker addCustomButtonWithTitle:title actionBlock:^{
NSLog(@"Test block invoked");
}];

[_sheetStringPicker showActionSheetPicker];
XCTAssertNotNil(_sheetStringPicker);
}

- (void)testPickerWithCustomActionBlockOnButtonAndNilString
{
[_sheetStringPicker addCustomButtonWithTitle:nil actionBlock:^{
NSLog(@"Test block invoked");
}];

[_sheetStringPicker showActionSheetPicker];
XCTAssertNotNil(_sheetStringPicker);
}

@end

0 comments on commit ab80aff

Please sign in to comment.