Skip to content

Commit

Permalink
Merge pull request #3452 from morozov/issues/3451
Browse files Browse the repository at this point in the history
Fixed AppVeyor build configuration and the issue on SQL Server
  • Loading branch information
Ocramius authored Feb 9, 2019
2 parents 92920ed + ccc6a0a commit 4a556cb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
14 changes: 11 additions & 3 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,17 +131,25 @@ before_test:
}
test_script:
- cd C:\projects\dbal
- ps: >-
if ($env:db_version) {
$env:phpunit_config = "tests\appveyor\$($env:db).$($env:db_version).$($env:driver).appveyor.xml"
} else {
$env:phpunit_config = "tests\appveyor\$($env:db).$($env:driver).appveyor.xml"
}
- ps: >-
if ($env:coverage -eq "yes") {
vendor\bin\phpunit -c $($env:phpunit_config) --coverage-clover clover.xml
appveyor-retry ocular code-coverage:upload --format=php-clover clover.xml
} else {
vendor\bin\phpunit -c $($env:phpunit_config)
}
if ($LastExitCode -ne 0) {
$host.SetShouldExit($LastExitCode)
}
after_test:
- ps: >-
if ($env:coverage -eq "yes") {
appveyor-retry ocular code-coverage:upload --format=php-clover clover.xml
}
2 changes: 1 addition & 1 deletion lib/Doctrine/DBAL/Platforms/SQLServerPlatform.php
Original file line number Diff line number Diff line change
Expand Up @@ -1278,7 +1278,7 @@ protected function doModifyLimitQuery($query, $limit, $offset = null)
// Even if the TOP n is very large, the use of a CTE will
// allow the SQL Server query planner to optimize it so it doesn't
// actually scan the entire range covered by the TOP clause.
if (! preg_match('/^(\s*SELECT\s+(?:DISTINCT\s+)?)(.*)$/im', $query, $matches)) {
if (! preg_match('/^(\s*SELECT\s+(?:DISTINCT\s+)?)(.*)$/is', $query, $matches)) {
return $query;
}

Expand Down

0 comments on commit 4a556cb

Please sign in to comment.