Skip to content

Latest commit

 

History

History
209 lines (161 loc) · 8.68 KB

ContinuousIntegration.md

File metadata and controls

209 lines (161 loc) · 8.68 KB

Introduction

Seattle Testbed components can be built and tested automatically on multiple operating systems using different versions of Python. This document describes how to configure Travis-CI and AppVeyor, two continuous integration web tools, in order to perform automated building and unit testing.

Configuration and Usage

First, add the configuration files for Travis-CI and AppVeyor to the repo for which you want to enable continuous integration.

The config files (currently appveyor.yml and .travis.yml) should already be in your fork/branch.

  • If not, make sure that your fork is in sync with the original SeattleTestbed repo, and
  • that your <feature> branch is in sync with your master branch (Hint: $ git merge master).
  • If the config files still aren't there, add them to your repo following the instructions below.

Next, link your GitHub user accound with the Countinuous Integration service.

Running on Travis CI

Log in and enable continuous integration for a repo of your choice.

  1. Go to Travis-CI Website and sign in with your GitHub user ID and password
  2. Authorize application to access your GitHub account
  3. Go to your profile page
  4. Flick on the repo switch for the repo you want to build and test.

Note: If you are an administrator of the SeattleTestbed GitHub organization, you can also select SeattleTestbed's CI profile page and enable CI for repos there.

To actually trigger a test run,

  1. Commit and push something to your repo -- this triggers Travis to run the tests
  2. Go to travis-ci.org/<GitHub-user>/<repo>/ to see build and test results.

You may contemplate to optionally add Travis-CI Build Status Badges to your README.md file on GitHub.

Running on AppVeyor

Again, you need to log in and enable AppVeyor CI for your repo first.

  1. Go to AppVeyor Website and log in with your GitHub user ID and password
  2. Authorize application to access your GitHub account
  3. Click on NEW PROJECT
  4. Authorize application to access your GitHub repositories
  5. Add the repo you want to build and test

Trigger a test run:

  1. Commit and push something to your repo or click NEW BUILD on the AppVeyor web interface, and
  2. Go to ci.appveyor.com/project/<GitHub-user>/<repo>/ to see your test and build results

Optionally add AppVeyor Build Status Badges to your README.md file on GitHub*

Note: Both systems can be instructed to skip testing of a commit by adding [skip ci] to the commit message.

## Sync config changes with SeattleTestbed repos The CI configuration files are maintained at [SeattleTestbed/continuous-integration](https://github.com/SeattleTestbed/continuous-integration). Different ideas of distributing them across all SeattleTestbed components are discussed in SeattleTestbed/continuous-integration#1. If you want to change the files or add new configs, please 1. push the changes to said repo, 1. use script `git_sync_configs.sh` to distribute files *(maybe you have to modify some hardcoded links/filenames)*, 1. submit Pull Requests in all affected SeattleTestbed components ## Further Readings *...are currently commented out to make the page less convoluted and they might disappear entirely at some point. If you want to read them now and in the browser click on the raw button on top.*