mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-08 04:18:52 +00:00
Merge branch '3.2.x'
This commit is contained in:
commit
beed8821ff
2 changed files with 20 additions and 11 deletions
|
@ -15,10 +15,10 @@ environment:
|
||||||
php: 7.0
|
php: 7.0
|
||||||
- db: mssql
|
- db: mssql
|
||||||
db_version: sql2016
|
db_version: sql2016
|
||||||
php: 7.0
|
php: 7.1.12
|
||||||
- db: mssql
|
# - db: mssql
|
||||||
db_version: sql2017
|
# db_version: sql2017
|
||||||
php: 7.1
|
# php: 7.1
|
||||||
# - db: mariadb
|
# - db: mariadb
|
||||||
# php: 7.1
|
# php: 7.1
|
||||||
# - db: mysqli
|
# - db: mysqli
|
||||||
|
@ -40,10 +40,10 @@ before_test:
|
||||||
- ps: |
|
- ps: |
|
||||||
Set-Service wuauserv -StartupType Manual
|
Set-Service wuauserv -StartupType Manual
|
||||||
cinst -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
|
cinst -y php --version ((choco search php --exact --all-versions -r | select-string -pattern $env:php | sort { [version]($_ -split '\|' | select -last 1) } -Descending | Select-Object -first 1) -replace '[php|]','')
|
||||||
Get-ChildItem -Path "c:\tools\php$($env:php -replace '[.]','')" -Recurse |
|
Get-ChildItem -Path "c:\tools\php$($env:php -replace '([0-9])[.]([0-9])[.]?([0-9]+)?','$1$2')" -Recurse |
|
||||||
Move-Item -destination "c:\tools\php"
|
Move-Item -destination "c:\tools\php"
|
||||||
cd c:\tools\php
|
cd c:\tools\php
|
||||||
cat php.ini-production | %{$_ -replace "memory_limit = 128M","memory_limit = 1024M"} | Out-File -Encoding "Default" php.ini
|
cat php.ini-development | %{$_ -replace "memory_limit = 128M","memory_limit = 1024M"} | Out-File -Encoding "Default" php.ini
|
||||||
Add-Content php.ini "`n date.timezone=UTC"
|
Add-Content php.ini "`n date.timezone=UTC"
|
||||||
Add-Content php.ini "`n display_errors=On"
|
Add-Content php.ini "`n display_errors=On"
|
||||||
Add-Content php.ini "`n extension_dir=ext"
|
Add-Content php.ini "`n extension_dir=ext"
|
||||||
|
@ -64,10 +64,10 @@ before_test:
|
||||||
if ($env:db -eq "mssql") {
|
if ($env:db -eq "mssql") {
|
||||||
cd c:\tools\php\ext
|
cd c:\tools\php\ext
|
||||||
$DLLVersion = "4.1.6.1"
|
$DLLVersion = "4.1.6.1"
|
||||||
appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/sqlsrv/$($:DLLVersion)/php_sqlsrv-$($DLLVersion)-$($env:php)-nts-vc14-x64.zip
|
appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/sqlsrv/$($:DLLVersion)/php_sqlsrv-$($DLLVersion)-$($env:php -replace '([0-9])[.]([0-9])[.]?([0-9]+)?','$1.$2')-nts-vc14-x64.zip
|
||||||
7z x -y php_sqlsrv-$($DLLVersion)-$($env:php)-nts-vc14-x64.zip > $null
|
7z x -y php_sqlsrv-$($DLLVersion)-$($env:php -replace '([0-9])[.]([0-9])[.]?([0-9]+)?','$1.$2')-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)-nts-vc14-x64.zip
|
appveyor-retry appveyor DownloadFile http://windows.php.net/downloads/pecl/releases/pdo_sqlsrv/$($DLLVersion)/php_pdo_sqlsrv-$($DLLVersion)-$($env:php -replace '([0-9])[.]([0-9])[.]?([0-9]+)?','$1.$2')-nts-vc14-x64.zip
|
||||||
7z x -y php_pdo_sqlsrv-$($DLLVersion)-$($env:php)-nts-vc14-x64.zip > $null
|
7z x -y php_pdo_sqlsrv-$($DLLVersion)-$($env:php -replace '([0-9])[.]([0-9])[.]?([0-9]+)?','$1.$2')-nts-vc14-x64.zip > $null
|
||||||
Remove-Item c:\tools\php\* -include .zip
|
Remove-Item c:\tools\php\* -include .zip
|
||||||
cd c:\tools\php
|
cd c:\tools\php
|
||||||
Add-Content php.ini "`nextension=php_sqlsrv.dll"
|
Add-Content php.ini "`nextension=php_sqlsrv.dll"
|
||||||
|
@ -114,6 +114,10 @@ before_test:
|
||||||
# Install PhantomJS
|
# Install PhantomJS
|
||||||
cinst -y phantomjs
|
cinst -y phantomjs
|
||||||
Start-Process "phantomjs" "--webdriver=8910" | Out-Null
|
Start-Process "phantomjs" "--webdriver=8910" | Out-Null
|
||||||
|
- ps: |
|
||||||
|
cd c:\projects\phpbb\phpBB
|
||||||
|
(Get-Content c:\projects\phpbb\phpBB\web.config).replace("<configuration>", "<configuration>`n`t<system.web>`n`t`t<customErrors mode=`"Off`"/>`n`t</system.web>") | Set-Content c:\projects\phpbb\phpBB\web.config
|
||||||
|
(Get-Content c:\projects\phpbb\phpBB\web.config).replace("`t</system.webServer>", "`t`t<httpErrors errorMode=`"Detailed`" />`n`t</system.webServer>") | Set-Content c:\projects\phpbb\phpBB\web.config
|
||||||
- cd c:\projects\phpbb\phpBB
|
- cd c:\projects\phpbb\phpBB
|
||||||
- php ..\composer.phar install
|
- php ..\composer.phar install
|
||||||
- choco install -y urlrewrite
|
- choco install -y urlrewrite
|
||||||
|
|
|
@ -910,10 +910,15 @@ class phpbb_functional_test_case extends phpbb_test_case
|
||||||
* status code. This assertion tries to catch that.
|
* status code. This assertion tries to catch that.
|
||||||
*
|
*
|
||||||
* @param int $status_code Expected status code
|
* @param int $status_code Expected status code
|
||||||
* @return null
|
* @return void
|
||||||
*/
|
*/
|
||||||
static public function assert_response_status_code($status_code = 200)
|
static public function assert_response_status_code($status_code = 200)
|
||||||
{
|
{
|
||||||
|
if ($status_code != self::$client->getResponse()->getStatus() &&
|
||||||
|
preg_match('/^5[0-9]{2}/', self::$client->getResponse()->getStatus()))
|
||||||
|
{
|
||||||
|
self::fail("Encountered unexpected server error:\n" . self::$client->getResponse()->getContent());
|
||||||
|
}
|
||||||
self::assertEquals($status_code, self::$client->getResponse()->getStatus(), 'HTTP status code does not match');
|
self::assertEquals($status_code, self::$client->getResponse()->getStatus(), 'HTTP status code does not match');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue