Related: Code coverage Coveralls.io setup
Continuous Integration service (self-check code on each
git push) has free private builds for educational users, and free public builds for all.
Free continuous integration
These CI services are free for public repositories.
Some have usage limits (e.g. minutes/month).
Even for unlimited services like Travis CI, I cancel build jobs if I make
git push in quick succession to save their resources from unneeded builds I know have errors.
git commit including
[ci skip] will not CI build, that seems to be a de facto standard.
|Gitlab||Mac, Linux, Windows|
Travis-CI can compile in almost any language, for Mac and Linux, with various compiler versions.
HDF5 + Fortran on Travis is difficult to use, because Ubuntu 14.04 is so old, with:
libhdf5-devon Travis requiring gfortran 4 or 5
- newest gfortran == 5.4 on Travis via ubuntu-test PPA doesn’t have variable
error stopFortran 2018 feature I commonly use (available in gfortran 6) – but Gfortran 6 isn’t compatible with libhdf5-dev on Ubuntu 14.04
What I do is to use AppVeyor instead for Ubuntu 16.04 and HDF5 Fortran tests.
Here are a few categories of simple multi-platform builds.
Python + Fortran
Python compiling 40 year old Fortran code: .travis.yml
C + HDF5 + Cmake
IPv6 C with HDF5 writing and Cmake: .travis.yml
C++ + Cmake
C++ and Cmake: .travis.yml
Pascal: .travis.yml example
Quick Start Travis-CI
- Create a free travis-ci.org account–perhaps using your Github credentials
- add a repository to Travis-CI
- copy a
.travis.ymltemplate from one of the examples above–for Python / pytest, a
tests/test_all.pyfile is expected. Perhaps look at one of the examples for ideas on how/what to test.
The key point is that Travis CI considers only
stderr == / != 0 for pass/fail:
A third case is an ERROR in setup, perhaps a misconfigured
setup.py in your project or missing prereq.
See my Coveralls.io page.
Appveyor is for Windows and Linux (Ubuntu 16.04), with selectable Windows versions.
- C++ and Fortran examples