This is a guest post by Craig Rodrigues


The FreeBSD project produces a modern operating system derived from BSD Unix.

In the past 6 months, we have set up Jenkins at https://jenkins.freebsd.org/, to continuously build FreeBSD as developers add new code to the project. This has helped us identify and fix build breaks very quickly.

We have gone even farther by integrating Jenkins, Kyua, and Bhyve. Kyua is a testing framework for infrastructure software. Bhyve is the native hypervisor that comes with FreeBSD (similar to KVM on Linux).

We use the Build Flow plugin in this example Build flow to do the following:

  1. Build the FreeBSD kernel and userland on amd64 whenever someone checks in new code to https://svn.freebsd.org

  2. Create a bootable FreeBSD disk image with makefs

  3. Boot the image under bhyve

  4. Run these commands inside the bhyve VM:

    cd /usr/tests; kyua test; kyua report-junit --output=test-output.xml
  1. Shut down the bhyve VM

  2. Imports test-output.xml into Jenkins.

  3. Produces a full native test report in Jenkins

The results of this work were presented at the Bay Area FreeBSD Users Group in this presentation in October 2014.

Jenkins has been very easy to set up and use under FreeBSD. We hope that by using Jenkins to run OS-level unit tests, we will be able to improve the quality of FreeBSD. For further information, please feel free to contact us at freebsd-testing@FreeBSD.org .

About the Author
Kohsuke Kawaguchi

Kohsuke is the creator of Jenkins.