Using Hudson with GHUnit
Hudon is a continuous integration server that has a broad set of support and plugins, and is easy to set up. You can use Hudson to run your GHUnit tests after every checkin, and report the results to your development group in a variety of ways (by email, to Campfire, and so on).
Here's how to set up Hudson with GHUnit.
Follow the instructions in the GHUnit README to set up a Makefile for your GHUnit project.
Manage Pluginsand install whatever plugins you need for your project. For instance, you might want to install the Git and GitHub plugins if you host your code on GitHub.
Create a new job for your project and click on
Configure. Most of the options are self-explanatory or can be figured out with the online help. You probably want to configure
Source Code Management, and then under
Poll SCMand add a schedule of
* * * * *(which checks your source control system for new changes once a minute).
Build, enter the following command:
make clean && WRITE_JUNIT_XML=YES make test
Post-build Actions, check
Publish JUnit test result reportand enter the following in
Test report XMLs:
That's all it takes. Check in a change that breaks one of your tests. Hudson should detect the change, run a build and test, and then report the failure. Fix the test, check in again, and you should see a successful build report.
If your XCode build fails with a set of font-related errors, you may be running Hudson headless (e.g., via an SSH session). Launch Hudson via Terminal.app on the build machine (or otherwise attach a DISPLAY to the session) in order to address this.