Fwd: Unit Testing Frameworks
Fwd: Unit Testing Frameworks
- Subject: Fwd: Unit Testing Frameworks
- From: Thaddeus Cooper <email@hidden>
- Date: Sun, 7 Dec 2008 14:36:14 -0800
Woops -- the highlighting didn't come through. Here is the line from
below:
2008-12-07 14:15:35.042 otest[42098:80f] The executable for the test
bundle at /Users/cooper/src/Sections/build/Debug/Tests.octest could
not be found.
Thaddeus O. Cooper
(email@hidden)
Begin forwarded message:
From: Thaddeus Cooper <email@hidden>
Date: December 7, 2008 2:25:37 PM PST
To: Cocoa-Dev Mail <email@hidden>
Subject: Unit Testing Frameworks
Hello all.
I am having a problem with setting up unit testing for frameworks.
I've read the documentation that is provided in the Apple doc set <http://developer.apple.com/documentation/DeveloperTools/Conceptual/UnitTesting/UnitTesting.pdf
> and found Chris Hanson's updates to that documentation at <http://chanson.livejournal.com/119303.html
>. I've set up the framework to include a new target with the Unit
Test Bundle and added my tests to it. I've also set up the
dependency so that the tests should be run when the framework gets
built (at least that's what I understand should happen), and I've
set the target membership for my framework so that my framework gets
linked into the tests.
The framework builds correctly -- no warnings or errors, but the
test cases do not get built automatically. I then switch my active
target to my test bundle (creatively named Tests), and do a build
and get the following error dump (note I've highlighted the line I
believe to be the major error):
/bin/sh -c /Users/cooper/src/Sections/build/Sections.build/Debug/
Tests.build/Script-1E7E14D00EEC6FD2006D87B7.sh
/Developer/Tools/RunPlatformUnitTests.include:358: note: Started
tests for architectures 'i386'
/Developer/Tools/RunPlatformUnitTests.include:365: note: Running
tests for architecture 'i386' (GC OFF)
objc[42098]: GC: forcing GC OFF because OBJC_DISABLE_GC is set
objc[42098]: GC: forcing GC OFF because OBJC_DISABLE_GC is set
2008-12-07 14:15:35.042 otest[42098:80f] The executable for the test
bundle at /Users/cooper/src/Sections/build/Debug/Tests.octest could
not be found.
2008-12-07 14:15:35.044 otest[42098:80f] Usage: otest [-SenTest Self
| All | None | <TestCaseClassName/testMethodName>] <path of unit to
be tested>
2008-12-07 14:15:35.046 otest[42098:80f] *** -[NSCFDictionary
setObject:forKey:]: attempt to insert nil value (key:
_NSTaskExecutablePath)
/Developer/Tools/RunPlatformUnitTests.include:384: error: Failed
tests for architecture 'i386' (GC OFF)
/Developer/Tools/RunPlatformUnitTests.include:393: note: Completed
tests for architectures 'i386'
I'm not sure why I'm getting this error, and what I should do to
correct it so the tests run correctly.
If anyone could shed some light on this for me I'd be really
appreciative.
Thanks very much.
Thaddeus O. Cooper
(email@hidden)
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden