[CMake] "unit" testing your CMakeLists.txt

Mike Arthur mike at mikearthur.co.uk
Wed Feb 11 07:30:40 EST 2009


On Monday 09 February 2009 20:15:33 Tyler Roscoe wrote:
> Does anyone do anything like this? Are there tools around to help? Is
> this a worthwhile thing to think about?
I think this shouldn't be separate from the rest of your other TDD stuff that 
the non-buildsystem developers are doing. 

In my mind TDD makes no sense without a continuous integration system and this 
means your packaging should be integrated into the buildsystem so that every 
revision that is committed is built, tested and packaged and any other tasks 
are run (e.g. documentation generation). You can and should just set up the 
continuous integration system to ensure these stages are completed 
successfully (such as get it actually running the packaged installer and the 
like).

Really I think going much beyond this is a bit overkill. We're dealing with a 
pretty complex project with external dependencies, multiple 
platforms/architectures and automatic packaging and subtle bugs just don't 
tend to creep into the buildsystem in the same way that they do with our C++ 
code.

I think the only real important thing from the buildsystem is the result and 
therefore just making sure the application can be run correctly should be 
enough.

-- 
Cheers,
Mike Arthur
http://mikearthur.co.uk/


More information about the CMake mailing list