Have a look at the async section of the docs (mainly the bit under ExampleAsyncTest.m:
). Something like:
-(void)testCase
{
[someObject postRequestWithBlock:^(BOOL succeeded, NSError *error) {
[self notify:succeeded ? kGHUnitWaitStatusSuccess : kGHUnitWaitStatusFailure forSelector:@selector(testCase)];
GHAssertTrue(succeeded&&!error, @"faile");
}];
[self waitForStatus:kGHUnitWaitStatusSuccess timeout:10.0];
}
I would recommend the Expecta testing framework too, its got a nice clean syntax.