The Test Tools project provides Python scripts to automatically:
- build binaries
of COIN-OR projects. If a failure is recognized, the scripts can send an e-mail to the corresponding project manager.
The Test Tools project is managed by JP Fasano. Contributors are JP Fasano, Kipp Martin, and Stefan Vigerske.
Currently stable version 0.1 of this project is available. To check this project out using svn execute the command:
svn co https://projects.coin-or.org/svn/TestTools/stable/0.1 COIN-TestTools
This will check out a set of Python scripts into the directory COIN-TestTools.
Usage of nightlyBuild
First, a user need to specify some parameters, e.g., the directory where nightlyBuild checks out and builds project.
Parameters for nightlyBuild are specified via two Python scripts:
- NBuserParametersDefault.py contains default values of all parameters. It should not be modified by the user since it receives updates together with other nightlyBuild scripts.
- NBuserParameters.py is the user specific parameter file. nightlyBuild reads this file after NBuserParametersDefault.py, so it should be used to overwrite default values.
To setup parameters, the user should
cp NBuserParametersDefault.py NBuserParameters.py vi NBuserParameters.py
The nightlyBuild parameters are documented in NBuserParametersDefault.py. See also the INSTALL file for more information.
The main script is nightlyBuild.py. Assuming Python is in your PATH variable you can invoke nightlyBuild by simply entering at the command line
What nightlyBuild does…
For each supported COIN-OR project a set of build types can be specified. A build type is a tuple of information containing the
- SvnVersion: which version from the repository to built (trunk, latestStable, latestRelease, stable/0.1, ...)?
- OptLevel: should the code be build in optimized mode ("Default") or debugging mode ("Debug")
- ThirdParty: should it be allowed to use third party codes
- SkipProjects: a list of COIN-OR projects (from the externals) that should be skipped in the build
- AdditionalConfigOptions: additional flags for the configure call
For such a build type, nightlyBuild does
- Checkout the specified version from the svn repository (https://projects.coin-or.org/svn/<project>/...).
- Download third party codes for which get.XXX scripts can be found.
- Assemble the parameter for the configure call.
- Call configure. If there is an error, send a failure report as e-mail and break.
- Call make. If there is an error, send a failure report as e-mail and break.
- If the project has a test program, call make test. If there is an error, send a failure report as e-mail and break.
- If the project has unit tests, call the unit tests. If there is an error, send a failure report as e-mail and break.
- Run make install which will put any libraries that are built into a lib directory, any executables into a bin directory and the necessary header files into an include directory. If there is an error, send a failure report as e-mail and break.
- If the user specifies BUILD_BINARIES = 1 then a zipped archive is created of the project libraries, binaries, and header files.
There are also rules implemented to avoid the rebuild and test of a project if there has been no change in the code since the last build.
The failure reports contain, next to information about the build type and the system, also the output to stdout and stderr and a config.log file if configure failed.
The output of get.XXX scripts, configure, make, unittests to stdout and stderr is also stored in the build directories for later analysis (e.g., NBmake.stdout).
See the INSTALL file for more information.
Where nightlyBuild is currently running…
See the page NightlyBuildInAction for a list of systems where the nightlyBuild scripts are running.