Created
October 4, 2012 13:46
-
-
Save dodikk/3833622 to your computer and use it in GitHub Desktop.
testStructAndBlocks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(void)testStructAndBlocks | |
{ | |
SDRefreshTraits traits_ = { YES, NO }; | |
__block BOOL forceRefresh_ = NO; | |
TestAsyncRequestBlock block_ = ^( JFFSimpleBlock finishBlock_ ) | |
{ | |
forceRefresh_ = traits_.forceRefresh; | |
finishBlock_(); | |
}; | |
[ self performAsyncRequestOnMainThreadWithBlock: block_ | |
selector: _cmd ]; | |
GHAssertTrue( forceRefresh_, @"block does not handle C struct properly" ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment