• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: SenTestingKit: Doing an STAssert...() from outside a SenTestCase subclass [solved]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SenTestingKit: Doing an STAssert...() from outside a SenTestCase subclass [solved]


  • Subject: Re: SenTestingKit: Doing an STAssert...() from outside a SenTestCase subclass [solved]
  • From: Ruotger Skupin <email@hidden>
  • Date: Wed, 15 Feb 2006 16:55:22 +0100

Hi,

I got something that works. Add this method to your class:

- (void) failWithException:(NSException *) e
{
	printf("%s:%i: error: %s\n",
		   [[[e userInfo] objectForKey:SenTestFilenameKey] cString],
		   [[[e userInfo] objectForKey:SenTestLineNumberKey] intValue],
		   [[[e userInfo] objectForKey:SenTestDescriptionKey] cString]);
}


Ruotger Skupin

Am 15.02.2006 um 12:03 schrieb Ruotger Skupin:

Hi,

the macros STFail() and STAssert...() all map to [self failWithException:] which is obviously a method from SenTestCase which means they can't be used in a class which is not a subclass of SenTestCase.

Has someone found an *easy* way to use them outside a subclass of SenTestCase?

regards
	Ruotger Skupin

---
"Less code is better code" - Wil Shipley

Ruotger Skupin, Mac OS X Software Engineering

ilink Kommunikationssysteme GmbH
Münzstr. 13; 10178 Berlin - Germany



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40ilink.de


This email sent to email@hidden

--- "Less code is better code" - Wil Shipley

Ruotger Skupin, Mac OS X Software Engineering

ilink Kommunikationssysteme GmbH
Münzstr. 13; 10178 Berlin - Germany



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >SenTestingKit: Doing an STAssert...() from outside a SenTestCase subclass (From: Ruotger Skupin <email@hidden>)

  • Prev by Date: Re: problem with addTrackingRectangle
  • Next by Date: Re: CoreImage: Newbie can't find memory leak
  • Previous by thread: SenTestingKit: Doing an STAssert...() from outside a SenTestCase subclass
  • Next by thread: Authorization Plug-in with GUI
  • Index(es):
    • Date
    • Thread