Skip to content

Commit

Permalink
Fixed MSSQL expected test result: we're adding ORDER BY (SELECT NULL)…
Browse files Browse the repository at this point in the history
… to limit and order queries and query params are empty array by default
  • Loading branch information
samdark committed Jan 30, 2016
1 parent c36e679 commit e6f1179
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tests/framework/db/mssql/MssqlQueryBuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ class MssqlQueryBuilderTest extends QueryBuilderTest

public function testOffsetLimit()
{
$expectedQuerySql = 'SELECT [id] FROM [exapmle] OFFSET 5 ROWS FETCH NEXT 10 ROWS ONLY';
$expectedQueryParams = null;
$expectedQuerySql = 'SELECT [id] FROM [example] ORDER BY (SELECT NULL) OFFSET 5 ROWS FETCH NEXT 10 ROWS ONLY';
$expectedQueryParams = [];

$query = new Query();
$query->select('id')->from('example')->limit(10)->offset(5);
Expand All @@ -30,8 +30,8 @@ public function testOffsetLimit()

public function testLimit()
{
$expectedQuerySql = 'SELECT [id] FROM [exapmle] OFFSET 0 ROWS FETCH NEXT 10 ROWS ONLY';
$expectedQueryParams = null;
$expectedQuerySql = 'SELECT [id] FROM [example] ORDER BY (SELECT NULL) OFFSET 0 ROWS FETCH NEXT 10 ROWS ONLY';
$expectedQueryParams = [];

$query = new Query();
$query->select('id')->from('example')->limit(10);
Expand All @@ -44,8 +44,8 @@ public function testLimit()

public function testOffset()
{
$expectedQuerySql = 'SELECT [id] FROM [example] OFFSET 10 ROWS';
$expectedQueryParams = null;
$expectedQuerySql = 'SELECT [id] FROM [example] ORDER BY (SELECT NULL) OFFSET 10 ROWS';
$expectedQueryParams = [];

$query = new Query();
$query->select('id')->from('example')->offset(10);
Expand Down

0 comments on commit e6f1179

Please sign in to comment.