Skip to content

Commit

Permalink
Merge branch '4.0-dev' into dep-finder-strings
Browse files Browse the repository at this point in the history
  • Loading branch information
brianteeman committed Apr 1, 2018
2 parents 4d82692 + a9ee46c commit 84af33a
Show file tree
Hide file tree
Showing 70 changed files with 1,049 additions and 1,711 deletions.
51 changes: 33 additions & 18 deletions .appveyor.yml
Expand Up @@ -7,6 +7,7 @@ environment:
matrix:
- php_ver_target: 7.0
- php_ver_target: 7.1
- php_ver_target: 7.2

init:
- SET PATH=C:\Program Files\OpenSSL;C:\tools\php;%PATH%
Expand All @@ -23,45 +24,61 @@ services:
install:
- IF EXIST C:\tools\php (SET PHP=0)
- ps: >-
appveyor-retry cinst --params '""/InstallDir:C:\tools\php""' --ignore-checksums -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php_ver_target | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
$VC = "vc14"
$PHPBuild = "x64"
If ($env:PHP -eq "1") {
appveyor-retry cinst --params '""/InstallDir:C:\tools\php""' --ignore-checksums -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php_ver_target | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
$VC = "vc14"
$PHPBuild = "x64"
}
- appveyor-retry cinst -y sqlite
- cd C:\tools\php
# Get the MSSQL DLL's
- ps: >-
If ($env:PHP -eq "1") {
$DLLVersion = "4.1.6.1"
cd c:\tools\php\ext
appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/sqlsrv/$($DLLVersion)/php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip
7z x -y php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip > $null
appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/pdo_sqlsrv/$($DLLVersion)/php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip
7z x -y php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip > $null
Remove-Item c:\tools\php\ext* -include .zip
cd c:\tools\php
}
$DLLVersion = "4.3.0"
cd c:\tools\php\ext
$source = "http://windows.php.net/downloads/pecl/releases/sqlsrv/$($DLLVersion)/php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip"
$destination = "c:\tools\php\ext\php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip"
Invoke-WebRequest $source -OutFile $destination
#appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/sqlsrv/$($DLLVersion)/php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip
7z x -y php_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip > $null
$source = "http://windows.php.net/downloads/pecl/releases/pdo_sqlsrv/$($DLLVersion)/php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip"
$destination = "c:\tools\php\ext\php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip"
Invoke-WebRequest $source -OutFile $destination
#appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/pdo_sqlsrv/$($DLLVersion)/php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip
7z x -y php_pdo_sqlsrv-$($DLLVersion)-$($env:php_ver_target)-nts-vc14-x64.zip > $null
Remove-Item c:\tools\php\ext* -include .zip
cd c:\tools\php}
- IF %PHP%==1 copy php.ini-production php.ini /Y
- IF %PHP%==1 echo date.timezone="UTC" >> php.ini
- IF %PHP%==1 echo extension_dir=ext >> php.ini
- IF %PHP%==1 echo extension=php_openssl.dll >> php.ini
- IF %PHP%==1 echo extension=php_mbstring.dll >> php.ini
- IF %PHP%==1 echo extension=php_fileinfo.dll >> php.ini
- IF %PHP%==1 echo extension=php_gd2.dll >> php.ini
- IF %PHP%==1 echo extension=php_sqlsrv.dll >> php.ini
- IF %PHP%==1 echo extension=php_pdo_sqlsrv.dll >> php.ini

- ps: >-
If ($env:PHP -eq "1") {
Add-Content php.ini "`nextension=php_sqlsrv.dll"
Add-Content php.ini "`nextension=php_pdo_sqlsrv.dll"
Add-Content php.ini "`n"}
- IF %PHP%==1 echo extension=php_pgsql.dll >> php.ini
- IF %PHP%==1 echo extension=php_pdo_pgsql.dll >> php.ini
- IF %PHP%==1 echo extension=php_pdo_sqlite.dll >> php.ini
- IF %PHP%==1 echo extension=php_sqlite3.dll >> php.ini
- IF %PHP%==1 echo extension=php_pdo_mysql.dll >> php.ini
- IF %PHP%==1 echo extension=php_mysqli.dll >> php.ini
- IF %PHP_VER_TARGET%==5.6 IF %PHP%==1 echo extension=php_mysql.dll >> php.ini
- IF %PHP%==1 echo extension=php_curl.dll >> php.ini
# Get the Wincache DLLs
- ps: >-
If ($env:PHP -eq "1") {
$wincache = "2.0.0.8"
cd c:\tools\php\ext
appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/wincache/$($wincache)/php_wincache-$($wincache)-$($env:php_ver_target)-nts-$($VC)-$($PHPBuild).zip
$source = "http://windows.php.net/downloads/pecl/releases/wincache/$($wincache)/php_wincache-$($wincache)-$($env:php_ver_target)-nts-$($VC)-$($PHPBuild).zip"
$destination = "c:\tools\php\ext\php_wincache-$($wincache)-$($env:php_ver_target)-nts-$($VC)-$($PHPBuild).zip"
Invoke-WebRequest $source -OutFile $destination
#appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/wincache/$($wincache)/php_wincache-$($wincache)-$($env:php_ver_target)-nts-$($VC)-$($PHPBuild).zip
7z x -y php_wincache-$($wincache)-$($env:php_ver_target)-nts-$($VC)-$($PHPBuild).zip > $null
Remove-Item C:\tools\php\ext* -include .zip
cd c:\tools\php}
Expand All @@ -74,14 +91,12 @@ install:
- appveyor-retry appveyor DownloadFile https://getcomposer.org/composer.phar
- cd C:\projects\joomla-cms
- appveyor-retry composer install --no-progress --profile

before_test:
# Database setup for MySQL via PowerShell tools
- >
"C:\Program Files\MySQL\MySQL Server 5.7\bin\mysql" -u root -p"Password12!" -e "CREATE DATABASE IF NOT EXISTS joomla_ut;"
- >
"C:\Program Files\MySQL\MySQL Server 5.7\bin\mysql" -u root -p"Password12!" joomla_ut < tests\unit\schema\mysql.sql
# Database setup for PostgreSQL
- SET PGUSER=postgres
- SET PGPASSWORD=Password12!
Expand All @@ -96,4 +111,4 @@ before_test:

test_script:
- cd C:\projects\joomla-cms
- libraries/vendor/bin/phpunit -c appveyor-phpunit.xml
- libraries/vendor/bin/phpunit --configuration ./libraries/vendor/joomla/test-unit/phpunit.xml.dist
56 changes: 53 additions & 3 deletions .drone.yml
Expand Up @@ -10,10 +10,32 @@ pipeline:
- /root/.composer/vendor/bin/phpcs --report=full --extensions=php -p --standard=build/phpcs/Joomla .
- echo $(date)

initdb:
image: joomlaprojects/docker-php70:develop
commands:
- composer install

php70-unit:
group: unit
image: joomlaprojects/docker-php70:develop
commands:
- ./libraries/vendor/bin/phpunit --configuration ./libraries/vendor/joomla/test-unit/phpunit.xml.dist

php71-unit:
group: unit
image: joomlaprojects/docker-php71:develop
commands:
- ./libraries/vendor/bin/phpunit --configuration ./libraries/vendor/joomla/test-unit/phpunit.xml.dist

php72-unit:
group: unit
image: joomlaprojects/docker-php72:develop
commands:
- ./libraries/vendor/bin/phpunit --configuration ./libraries/vendor/joomla/test-unit/phpunit.xml.dist

javascript:
image: joomlaprojects/docker-systemtests:latest
commands:
- echo $(date)
- apt-get install nodejs npm
- ln -s /usr/bin/nodejs /usr/bin/node
- export DISPLAY=:0
Expand All @@ -22,6 +44,34 @@ pipeline:
- mv -f drone-package.json package.json
- fluxbox > /dev/null 2>&1 &
- npm install
- node_modules/karma/bin/karma start karma.conf.js --single-run
- echo $(date)
- node_modules/karma/bin/karma start node_modules/joomla-javascript-tests/src/karma.conf.js --single-run

system-tests:
image: joomlaprojects/docker-systemtests:latest
commands:
- date
- apache2ctl -D FOREGROUND &
- google-chrome --version
- apt-get update > /dev/null 2>&1
- composer update > /dev/null 2>&1
- chmod 755 libraries/vendor/joomla-projects/selenium-server-standalone/bin/webdrivers/chrome/linux/chromedriver
- mv libraries/vendor/joomla/test-system/src/acceptance.suite.dist.yml libraries/vendor/joomla/test-system/src/acceptance.suite.yml
- libraries/vendor/bin/robo run:tests
- date

services:
mysql:
image: mysql:5.7
environment:
MYSQL_USER: joomla_ut
MYSQL_PASSWORD: joomla_ut
MYSQL_ROOT_PASSWORD: joomla_ut

memcached:
image: memcached:alpine

redis:
image: redis:alpine

postgres:
image: postgres
30 changes: 7 additions & 23 deletions .travis.yml
Expand Up @@ -3,39 +3,23 @@ sudo: false

language: php

env:
global:
- RUN_UNIT_TESTS="yes"
- INSTALL_MEMCACHE="yes"
- INSTALL_MEMCACHED="yes"
- INSTALL_REDIS="yes"

matrix:
fast_finish: true
include:
- php: 7.0
env: INSTALL_APCU="yes" INSTALL_MEMCACHE="no" INSTALL_LIBSODIUM="yes"
- php: 7.1
env: INSTALL_APCU="yes" INSTALL_MEMCACHE="no" INSTALL_LIBSODIUM="yes"
- php: 7.2
env: INSTALL_APCU="yes" INSTALL_MEMCACHE="no" INSTALL_LIBSODIUM="no"
- php: nightly
env: INSTALL_APCU="yes" INSTALL_MEMCACHE="no" INSTALL_MEMCACHED="no" INSTALL_LIBSODIUM="no"
allow_failures:
- php: 7.2
- php: nightly

services:
- memcache
- memcached
- redis-server

before_script:
# Make sure all dev dependencies are installed
- if [[ $RUN_UNIT_TESTS == "yes" ]]; then bash build/travis/unit-tests.sh $PWD; fi
# Abort travis execution if setup fails
- set -e
# Disable xdebug.
- phpenv config-rm xdebug.ini || echo "xdebug not available"
# Make sure all dev dependencies are installed, ignore platform requirements because Travis is missing the LDAP tooling on all new images
- composer install --ignore-platform-reqs

script:
- if [[ $RUN_UNIT_TESTS == "yes" ]]; then libraries/vendor/bin/phpunit --configuration travisci-phpunit.xml; fi
- libraries/vendor/bin/phpunit --configuration ./libraries/vendor/joomla/test-unit/phpunit.xml.dist

branches:
except:
Expand Down
75 changes: 0 additions & 75 deletions Jenkinsfile

This file was deleted.

6 changes: 0 additions & 6 deletions RoboFile.dist.ini

This file was deleted.

0 comments on commit 84af33a

Please sign in to comment.