Your NSOperation is probably running on a background thread managed by the NSOperationQueue. Your test needs to wait until the NSOperationQueue has processed all its tasks.
-Heath Borders heath.bord...@gmail.com Twitter: heathborders http://heath-tech.blogspot.com On Tue, Mar 22, 2011 at 10:35 PM, Shane <software.research.developm...@gmail.com> wrote: > Hi, > > I am trying to write a unit test for a class that inherits from > NSOperation. And I've implemented this class just as I did in my > application (which works) and the test case is running, but when the > 'addOperation:myClass' on the NSOperationQueue is called within the > test method, I don't see that my NSOperation class is being executed. > > Is there something different about running NSOperations within a unit test? > _______________________________________________ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > http://lists.apple.com/mailman/options/cocoa-dev/heath.borders%40gmail.com > > This email sent to heath.bord...@gmail.com > _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com