Skip to content

Commit

Permalink
Also travis test on OSX
Browse files Browse the repository at this point in the history
  • Loading branch information
jankatins committed May 13, 2016
1 parent a081831 commit 308310c
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .travis-build.sh
Expand Up @@ -23,8 +23,9 @@ travis_fold end Building
travis_fold start Checking
bootstrap_header 'Checking package'
export PKG_TARBALL=$(Rscript -e "with(as.list(read.dcf('DESCRIPTION')[1, ]), cat(sprintf('%s_%s.tar.gz', Package, Version)))")
export CHECK_LOG=${TRAVIS_BUILD_DIR}/IRkernel.Rcheck/00check.log
export INSTALL_LOG=${TRAVIS_BUILD_DIR}/IRkernel.Rcheck/00install.out
R CMD check $PKG_TARBALL # could also use --as-cran
export CHECK_LOG=/home/travis/build/IRkernel/IRkernel/IRkernel.Rcheck/00check.log
travis_fold end Checking

travis_fold start Installing
Expand All @@ -35,7 +36,11 @@ travis_fold end Installing
travis_fold start Python_env
bootstrap_header 'Installing Python Environment for testing'
# http://conda.pydata.org/docs/travis.html
wget https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh;
if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
wget https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
fi
bash miniconda.sh -b -p $HOME/miniconda
export PATH="$HOME/miniconda/bin:$PATH"
hash -r
Expand Down
14 changes: 14 additions & 0 deletions .travis.yml
@@ -1,3 +1,7 @@
os:
# - linux
- osx

language: r
sudo: false
cache: packages
Expand All @@ -13,15 +17,25 @@ env:

r_packages:
- devtools
- Cairo # this was missing on OSX, no idea why this wasn't installed :-( Needed for repr

r_github_packages:
# we currently still need IRdisplay from github in all cases...
- IRkernel/IRdisplay


script:
- echo ${TRAVIS_BUILD_DIR}
- pwd
- source .travis-build.sh
- grep -q -R 'WARNING' "$CHECK_LOG" ; [ $? -ne 0 ]
# TODO: currently we do have 1 NOTE: Found the following assignments to the global environment...
#- grep -q -R 'NOTE' "$CHECK_LOG"; [ $? -ne 0 ]

after_failure:
- travis_fold start check_log
- bootstrap_header 'Check log'
- cat "$CHECK_LOG"
- bootstrap_header 'Install log'
- cat "$INSTALL_LOG"
- travis_fold end check_log

0 comments on commit 308310c

Please sign in to comment.