dev/run_travis.sh in passenger-4.0.10 vs dev/run_travis.sh in passenger-4.0.13

- old
+ new

@@ -19,13 +19,37 @@ { echo "$ $@" "$@" } +function apt_get_update() { + if [[ "$apt_get_updated" = "" ]]; then + apt_get_updated=1 + run sudo apt-get update + fi +} + +function install_test_deps_without_rails_bundles() +{ + if [[ "$install_test_deps_without_rails_bundles" = "" ]]; then + install_test_deps_without_rails_bundles=1 + run rake test:install_deps RAILS_BUNDLES=no + fi +} + +function install_test_deps_without_rails_bundles_without_doctools() +{ + if [[ "$install_test_deps_without_rails_bundles_without_doctools" = "" ]]; then + install_test_deps_without_rails_bundles_without_doctools=1 + rake test:install_deps RAILS_BUNDLES=no DOCTOOLS=no + fi +} + run uname -a run lsb_release -a sudo tee /etc/dpkg/dpkg.cfg.d/02apt-speedup >/dev/null <<<"force-unsafe-io" +cp test/config.json.travis test/config.json if [[ "$TEST_RUBY_VERSION" != "" ]]; then echo "$ rvm use $TEST_RUBY_VERSION" if [[ -f ~/.rvm/scripts/rvm ]]; then source ~/.rvm/scripts/rvm @@ -54,37 +78,45 @@ run rake test:ruby fi if [[ "$TEST_NGINX" = 1 ]]; then run rake test:install_deps RAILS_BUNDLES=no DOCTOOLS=no - run gem install rack daemon_controller --no-rdoc --no-ri run ./bin/passenger-install-nginx-module --auto --prefix=/tmp/nginx --auto-download run rake test:integration:nginx fi if [[ "$TEST_APACHE2" = 1 ]]; then - run sudo apt-get update + apt_get_update run sudo apt-get install -y --no-install-recommends \ apache2-mpm-worker apache2-threaded-dev - run rake test:install_deps RAILS_BUNDLES=no DOCTOOLS=no - run gem install rack --no-rdoc --no-ri + install_test_deps_without_rails_bundles_without_doctools run ./bin/passenger-install-apache2-module --auto run rake test:integration:apache2 fi +if [[ "$TEST_STANDALONE" = 1 ]]; then + apt_get_update + install_test_deps_without_rails_bundles_without_doctools + run rake test:integration:standalone +fi + if [[ "$TEST_DEBIAN_PACKAGING" = 1 ]]; then - run sudo apt-get update + apt_get_update run sudo apt-get install -y --no-install-recommends \ devscripts debhelper rake apache2-mpm-worker apache2-threaded-dev \ - ruby1.8 ruby1.8-dev ruby1.9.1 ruby1.9.1-dev libev-dev gdebi-core \ + ruby1.8 ruby1.8-dev ruby1.9.1 ruby1.9.1-dev rubygems libev-dev gdebi-core \ source-highlight - run rake test:install_deps RAILS_BUNDLES=no - run rake debian:dev - run sudo gdebi -n pkg/ruby-passenger_*.deb - run sudo gdebi -n pkg/ruby-passenger-dev_*.deb - run sudo gdebi -n pkg/ruby-passenger-doc_*.deb - run sudo gdebi -n pkg/libapache2-mod-passenger_*.deb - run rvmsudo env LOCATIONS_INI=/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini \ - rspec -f s -c test/integration_tests/native_packaging_spec.rb + install_test_deps_without_rails_bundles + run rake debian:dev debian:dev:reinstall + run rake test:integration:native_packaging \ + LOCATIONS_INI=/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini \ + SUDO=1 run env PASSENGER_LOCATION_CONFIGURATION_FILE=/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini \ rake test:integration:apache2 SUDO=1 +fi + +if [[ "$TEST_SOURCE_PACKAGING" = 1 ]]; then + apt_get_update + run sudo apt-get install -y --no-install-recommends source-highlight + install_test_deps_without_rails_bundles + run rspec -f s -c test/integration_tests/source_packaging_test.rb fi