Skip navigation.
 
mlRe: SenTestingKit fails when using CG-Only
FROM : Timothy Reaves
DATE : Fri Nov 09 22:55:48 2007

On Nov 9, 2007, at 3:37 PM, Chris Hanson wrote:

> On Nov 9, 2007, at 9:07 AM, <email_removed> wrote:
>

>> I recently tried to get my test rig up and running in leopard, and 
>> my framework has been using GC only for a while now.
>> Setting up a custom executable to call otest on my test bundle, 
>> causese the following error:

>

>> Is this known, and if so, is there a workaround? If I have an app, 
>> and want to test a critical section, that uses only GC.... how can 
>> I accomplish that if SenTestingKit is gonna barf every time I throw 
>> GC-Only objects at it?

>
> The SenTestingKit.framework included with Xcode 3.0 is built GC-
> supported, so it's not at fault.  However, the otest test rig that 
> runs unit test bundles for frameworks is *not* built GC-supported in 
> Xcode 3.0.
>
> To run tests for your framework, you'll need to build your own test 
> rig, and then tell Xcode to use it in otest's place.
>
> You should be able to build your own test rig by just creating a 
> simple command-line tool that links Cocoa.framework and 
> SenTestingKit.framework, sets the SenTestTool user default in the 
> registration domain to YES (which indicates to the framework that a 
> test tool is being used), and then calls through to 
> SenSelfTestMain.  The SenTestTool user default and SenSelfTestMain 
> function are declared in <SenTestingKit/SenTestProbe.h>.
>
> To tell Xcode to use your test rig instead of otest, just set the 
> OTEST build setting to the path to your test rig.
>


   I also had to recompile the framework; otherwise, it'd link and run, 
but no tests were executed.

   Anyone testing please make sure to file a defect.  It's ridicules to 
have to jump through these hoops to be able to test.  You wouldn't 
tolerate compiling your own gcc to support gc.

Related mailsAuthorDate
mlSenTestingKit fails when using CG-Only listposter Nov 9, 18:07
mlRe: SenTestingKit fails when using CG-Only Chris Hanson Nov 9, 21:37
mlRe: SenTestingKit fails when using CG-Only Timothy Reaves Nov 9, 22:55
mlRe: SenTestingKit fails when using CG-Only Chris Hanson Nov 10, 03:19
mlRe: SenTestingKit fails when using CG-Only listposter Nov 10, 04:54