Loading ...
Sorry, an error occurred while loading the content.

138407Re: [XP] Group vote for C unit testing framework

Expand Messages
  • John Carter
    Jan 27, 2008
      On Thu, 24 Jan 2008, Hugo Garcia wrote:

      > C doesn't seem to have a "standard" library for unit testing like
      > other languages.
      > Which framework do you use?
      > If you are a framework author/contributor then please compare and
      > contrast if the other frameworks.

      Note 1. It's more important to get started with unit testing than to
      confront the team with a large and hairy framework that takes time to

      ie. Sometimes it's better to get just started with a simplest #define
      assert and actually write a unit test or three.

      Thereafter, you understand the need for some of the bells and whistle
      on the fancy frameworks.

      Note 2. Half the problem with C is legacy code. You need some way of
      stubbing out dependencies on the Big Ball of Mud legacy code so you
      unit test will at least run.

      Note 3. Dynamic languages sort out the "which module must link to
      what" problem automagically for you. With C the other half the puzzle
      is coping with the rapidly shifting link dependencies as the tests and
      main program evolve. (Especially if not all the team is committed to
      test driven development.)

      Hint: Control of the build environment is handy. Instead of using
      "make" which doesn't really give you all that much you care about
      anyway...knock up your own using a rich scripting language like Ruby
      or Python.

      John Carter Phone : (64)(3) 358 6639
      Tait Electronics Fax : (64)(3) 359 4632
      PO Box 1645 Christchurch Email : john.carter@...
      New Zealand
    • Show all 19 messages in this topic