Install homebrew packages through .travis.yml.

This commit is contained in:
Brad Warren 2019-01-09 15:08:47 -08:00
parent 5569b1ce19
commit 52c42b6927
2 changed files with 10 additions and 18 deletions

View file

@ -12,7 +12,6 @@ before_install:
- cp .travis.yml /tmp/travis.yml
- git pull origin master --strategy=recursive --strategy-option=theirs --no-edit
- if ! git diff .travis.yml /tmp/travis.yml ; then echo "Please merge master into test-everything"; exit 1; fi
- '[ "$TRAVIS_OS_NAME" != osx ] || tests/travis-macos-setup.sh'
before_script:
- 'if [ $TRAVIS_OS_NAME = osx ] ; then ulimit -n 1024 ; fi'
@ -122,9 +121,19 @@ matrix:
- language: generic
env: TOXENV=py27
os: osx
addons:
homebrew:
packages:
- augeas
- python2
- language: generic
env: TOXENV=py3
os: osx
addons:
homebrew:
packages:
- augeas
- python3
# Only build pushes to the master branch, PRs, and branches beginning with

View file

@ -1,17 +0,0 @@
#!/bin/bash -e
#
# Set up the test environment for macOS on Travis.
# Install the given package with brew if it's not already installed.
brew_install() {
if ! brew list "$1" > /dev/null 2>&1; then
brew install "$1"
fi
}
brew_install augeas
brew_install python
brew_install python3
# Ensure we use python from brew.
brew link python