diff --git a/.travis.yml b/.travis.yml index e209ae6a0c1..8decdf4a7cc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -37,8 +37,26 @@ matrix: env: WP_VERSION=latest WP_MULTISITE=0 RUN_PHPCS=1 - name: "E2E tests" php: 7.4 - script: + before_script: + - export PATH="$HOME/.composer/vendor/bin:$PATH" + - | + # Remove Xdebug for a huge performance increase: + if [ -f ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/xdebug.ini ]; then + phpenv config-rm xdebug.ini + else + echo "xdebug.ini does not exist" + fi - npm install + - composer install --no-dev + - | + # Install WP Test suite, install PHPUnit globally: + if [[ ! -z "$WP_VERSION" ]]; then + bash tests/bin/install.sh woocommerce_test root '' localhost $WP_VERSION + composer global require "phpunit/phpunit=5.7.*|7.5.*" + fi + - "/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16" + + script: - npm run build - docker-compose up --build -d - bash tests/bin/run-e2e-CI.sh