11language : php
2-
3- # # PHP versions to test against
42php :
5- - " 7.0"
6- - " 5.6"
7- - " 5.5"
8- - " 5.4"
9- - " 5.3"
10- - " 5.2"
3+ - ' 7.1'
4+ - ' 7.0'
5+ - ' 5.6'
6+ - ' 5.5'
7+ - ' 5.4'
8+ matrix :
9+ include :
10+ - php : ' 5.6'
11+ install : true
12+ before_script : chmod +x bin/wraith.sh
13+ env : TEST_SUITE=Wraith_Visual_Regression_Testing WRAITH_FAIL=5
14+ script : " ./bin/wraith.sh"
15+ - php : ' 5.3'
16+ dist : precise
1117sudo : false
18+ branches :
19+ except :
20+ - " /^*-v[0-9]/"
1221env :
13- - WP_VERSION=master WP_MULTISITE=0
22+ matrix :
23+ - WP_VERSION=latest WP_MULTISITE=0
24+ global :
25+ - MASTER_BRANCH=production UPSTREAM_REPO=Codeinwp/flymag STORE_URL=https://themeisle.com
26+ DEPLOY_BUILD=7.0
27+ before_install :
28+ - mkdir -p bin && cd bin
29+ - wget "$PIRATE_FLEET"load.sh
30+ - cd .. && chmod +x bin/load.sh
31+ - " . ./bin/load.sh"
1432install :
15- - . $HOME/.nvm/nvm.sh
16- - nvm install stable
17- - nvm use stable
18- - npm install
19- - npm install grunt-cli -g
20- before_script :
21- # # Install the wordpress latest version
22- - export WP_DEVELOP_DIR=/tmp/wordpress/
23- - mkdir -p $WP_DEVELOP_DIR
24- - git clone --depth=1 --branch="$WP_VERSION" git://develop.git.wordpress.org/ $WP_DEVELOP_DIR
25- - theme_slug=$(basename $(pwd))
26- - theme_dir=$WP_DEVELOP_DIR/src/wp-content/themes/$theme_slug
27- - cd ..
28- - mv $theme_slug $theme_dir
29- - cd $WP_DEVELOP_DIR
30- - cp wp-tests-config-sample.php wp-tests-config.php
31- - sed -i "s/youremptytestdbnamehere/wordpress_test/" wp-tests-config.php
32- - sed -i "s/yourusernamehere/root/" wp-tests-config.php
33- - sed -i "s/yourpasswordhere//" wp-tests-config.php
34- - mysql -e 'CREATE DATABASE wordpress_test;' -uroot
35-
36- # # install PHPCS and Wordpress standards
37- - pear install pear/PHP_CodeSniffer-2.8.1
38- - mkdir wordpress-coding-standards && curl -L https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/archive/master.tar.gz | tar xz --strip-components=1 -C wordpress-coding-standards
39- - phpenv rehash
40- - phpcs --config-set installed_paths $WP_DEVELOP_DIR/wordpress-coding-standards
41- - phpenv rehash
42- - cd $theme_dir
43-
33+ - chmod +x bin/install-dependencies.sh
34+ - " . ./bin/install-dependencies.sh"
4435script :
45- grunt travis
36+ - if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then grunt travis; fi;
37+ before_deploy :
38+ - openssl aes-256-cbc -K $encrypted_9b8ed05dcc21_key -iv $encrypted_9b8ed05dcc21_iv
39+ -in key.enc -out /tmp/key -d
40+ - chmod +x bin/prepare-deploy.sh
41+ - " . ./bin/prepare-deploy.sh"
42+ deploy :
43+ - provider : s3
44+ access_key_id : " $AWS_ACCESS_KEY"
45+ secret_access_key : " $AWS_SECRET_KEY"
46+ bucket : " $AWS_BUCKET"
47+ skip_cleanup : true
48+ acl : public_read
49+ overwrite : true
50+ local-dir : artifact/
51+ upload-dir : " $AWS_PRODUCTS_FOLDER/$THEMEISLE_REPO/latest"
52+ on :
53+ branch : " $MASTER_BRANCH"
54+ repo : " $UPSTREAM_REPO"
55+ condition : " $TRAVIS_PHP_VERSION = $DEPLOY_BUILD"
56+ - provider : s3
57+ access_key_id : " $AWS_ACCESS_KEY"
58+ secret_access_key : " $AWS_SECRET_KEY"
59+ bucket : " $AWS_BUCKET"
60+ skip_cleanup : true
61+ acl : public_read
62+ overwrite : true
63+ local-dir : artifact/
64+ upload-dir : " $AWS_PRODUCTS_FOLDER/$THEMEISLE_REPO/$THEMEISLE_VERSION"
65+ on :
66+ repo : " $UPSTREAM_REPO"
67+ branch : " $MASTER_BRANCH"
68+ condition : " $TRAVIS_PHP_VERSION = $DEPLOY_BUILD"
69+ after_deploy :
70+ - chmod +x bin/deploy.sh
71+ - " . ./bin/deploy.sh"
72+ after_failure :
73+ - cat logs/phpcs.log
0 commit comments