Re: NSObject -poseAs:
- Subject: Re: NSObject -poseAs:
- From: email@hidden
- Date: Thu, 31 May 2007 17:32:42 -0700
- Delivered-to: email@hidden
- Delivered-to: email@hidden
- Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=MTKocOqobNM6+Lnj2ANzEONycqU9OvfDKE/0MNcMqs+L9dv4qrwq9YgKJ4p+Uu79NJu9nZ5TYCzUj0Ibi2TKB1kht92FjJTRqPWy70R2/sB6NKA4t1GHFymQP4qAUEAnogQAkyCp4HgLNaBnWebuPe/tW0ohchcpqxAPrGHJPQg=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=cPBS3wU94uQoCn095Lh9BOn7wvROd0YgiVxRPGQGHSDBz8hfZwwNJue4/2HZLRe7u0mqYBHdQ4GkikeuAkUq1L8VvVGWyu3/FAIOYMlqvMjXDxi5PsrZMVvKcutRNpfVULIXpozhrrzbB6tqNkrQ8ILp6k1F7TBJigt5UHvLRiQ=
On 5/31/07, Mike R. Manzano <email@hidden> wrote:
[…]
@implementation TestThingToTest
- (void) testThingToTest
{
ThingToTest *thing = [[[ThingToTest alloc]init]autorelease];
[[MockSingletonClass class] poseAs:[SingletonClass]];
[thing methodToTest] ; // methodToTest uses the mock singleton
ctor
// Here's where it would be nice to unposeAs.
}
@end
[…]
could you instead use OCMock or does that also employ posing for mocking?
cheers,
jean-pierre
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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/email@hidden
This email sent to email@hidden
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.