From: Peter Rabbitson Date: Fri, 30 Nov 2012 15:45:07 +0000 (+0100) Subject: Throw away suboptimal travis CPANM env-option and tighten plans more X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c299fd651ef9882032bc0ea11966f0abe43b0839;p=dbsrgits%2FDBIx-Class-Historic.git Throw away suboptimal travis CPANM env-option and tighten plans more --- diff --git a/.travis.yml b/.travis.yml index 3abc1d7..8b8fd16 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,13 +23,15 @@ # WONTFIX "explanation") here: https://github.com/travis-ci/travis-ci/issues/497 # -# smoke only specific branches to a) not overload the queue and b) not +# Smoke only specific branches to a) not overload the queue and b) not # overspam the notification channels +# Furthermore if the branch is ^topic/ - the custom compiled smokes will +# not run at all, again in order to conserve queue resources branches: only: - master - - /^topic\// - /^smoke\// + - /^topic\// notifications: irc: @@ -103,7 +105,9 @@ install: - source maint/travis-ci_prepare_env script: - # either a plain 'make test' OR a shuffled prove torture - export HARNESS_TIMER=1 HARNESS_OPTIONS=c:j$NUMTHREADS + + # either a plain 'make test' OR a shuffled prove torture # use the random order test plan unless CLEANTEST - - test "$CLEANTEST" = "true" && make test || prove -lrswj$NUMTHREADS t xt + # prepare_env may have short-circuited the test entirely + - test -n "$SHORT_CIRCUIT_SMOKE" || (test "$CLEANTEST" = "true" && make test || prove -lrswj$NUMTHREADS t xt) diff --git a/maint/travis-ci_prepare_env b/maint/travis-ci_prepare_env index b336ac7..2f8f4d0 100755 --- a/maint/travis-ci_prepare_env +++ b/maint/travis-ci_prepare_env @@ -35,11 +35,18 @@ fi # if [[ -n "$BREWVER" ]] ; then + # if this is not master and not a smoke/ branch - cancel all testing + if [[ "$TRAVIS_BRANCH" =~ "topic/" ]]; then + export SHORT_CIRCUIT_SMOKE=1 + return # this is like an `exit 0` in sourcing + fi + perlbrew install --as $BREWVER --notest $BREWOPTS -j $NUMTHREADS perl-$BREWVER perlbrew use $BREWVER fi export PERL_MM_USE_DEFAULT=1 PERL_MM_NONINTERACTIVE=1 PERL_AUTOINSTALL_PREFER_CPAN=1 +export PERL_CPANM_OPT="$( echo $PERL_CPANM_OPT | sed 's/--skip-satisfied//' )" # configure CPAN.pm - older versions get tickled by M::AI and # go into an endless loop when trying to autoconf themselves @@ -102,11 +109,7 @@ installdeps() { if [[ -z "$@" ]] ; then return; fi echo -n "Installing $@... " - # FIXME - # the --reinstall is here because for some reason e.g. `cpanm Carp` does - # not install a newer Carp since it already exists on the system - # investigation pending - if ! OUT=$( echo "$@" | xargs -n 1 -P $NUMTHREADS cpanm --reinstall --verbose --notest 2>&1 ) ; then + if ! OUT=$( echo "$@" | xargs -n 1 -P $NUMTHREADS cpanm --verbose --notest 2>&1 ) ; then EX=$? echo "FAILED !!!" echo "$OUT" @@ -149,12 +152,6 @@ fi perl Makefile.PL installdeps $(make listalldeps) -# FIXME - for some reason the above invocation does not upgrade outdated -# core libs - just punt and install the remainder by hand (these run tests) -# This snippet should not be here at all -perl Makefile.PL &> /dev/null -make installdeps - # announce what are we running perl -V echo "Using $NUMTHREADS Travis-CI concurrent processes"