Re: Newbie - Using cppunit in XCode?
Re: Newbie - Using cppunit in XCode?
- Subject: Re: Newbie - Using cppunit in XCode?
- From: Chris Hanson <email@hidden>
- Date: Wed, 7 Dec 2005 08:07:44 -0800
On Dec 7, 2005, at 3:45 AM, Roel Wuyts wrote:
Googling for the problem I found a solution: I should include the
file libcppunit.a in my project, but I do not have such a file, and
so I am stuck. Anybody out there that uses XCode with C++ and can
help me out or that can tell me how they do unit testing (I am not
particularly atteched to cppunit) ?
Xcode 2.1 and later has unit testing support. Included are target
templates that enable you to build bundles containing tests that are
independent from the application or framework being tested, a script
that's used (automatically) by these targets to actually run the
tests as part of your build, file templates to make writing test
cases easy, and a pair of unit testing frameworks, OCUnit for
Objective-C/Cocoa and CPlusTest for C++.
Documentation to get started with can be found at the Apple Developer
Connection:
Unit Testing Guide
http://developer.apple.com/documentation/DeveloperTools/Conceptual/
UnitTesting/index.html
CPlusTest Reference
http://developer.apple.com/documentation/DeveloperTools/Reference/
CPlusTestReference/index.html
Note that CPlusTest does not assume you're using Carbon, so if you're
writing tests for an application you need to add some code in your
test bundle to hook in to the application to run tests. The example
given in the Unit Testing Guide installs a Carbon event loop timer
that causes the tests to run on the next iteration of the event loop.
-- Chris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden