set up multi-os testing in travis

Requires beta access, thankfully the travis gods have blessed us for the
main repo and my fork!

This should allow us to make sure scm_breeze operates reliably in both
Linux and BSD/Darwin, because there are small shell differences
(especially with default tools) that are causing errors I noticed on
MacOSX.
This commit is contained in:
Matthew Rothenberg
2014-10-15 12:57:28 -04:00
parent 885cc6fc12
commit 802f4987c3
2 changed files with 23 additions and 3 deletions

View File

@@ -1,3 +1,9 @@
script: ./run_tests.sh os:
before_script: - linux
- sudo apt-get install zsh - osx
install:
- ./test/support/travisci_deps.sh
script:
- ./run_tests.sh

14
test/support/travisci_deps.sh Executable file
View File

@@ -0,0 +1,14 @@
#!/usr/bin/env bash
# Installs dependencies for travis-ci environments.
# Install dependencies, which looks to be just bash & zsh.
#
# Darwin has zsh preinstalled already, so only need to install on Ubuntu.
#
# Note: $TRAVIS_OS_NAME will only be set on text boxes with multi-os enabled,
# so use negation test so it will fail gracefully on normal Travis linux setup.
#
# TODO: also perhaps later only on ZSH test box if we split those
if [[ "$TRAVIS_OS_NAME" != "osx" ]]; then
sudo apt-get install zsh
fi