Browse Source

Making test more resillient to different database servers

Jose Lorenzo Rodriguez 11 years ago
parent
commit
22e377fd76
1 changed files with 2 additions and 1 deletions
  1. 2 1
      tests/TestCase/Database/QueryTest.php

+ 2 - 1
tests/TestCase/Database/QueryTest.php

@@ -1477,10 +1477,11 @@ class QueryTest extends TestCase
             ->select(['id', 'author_id'])
             ->distinct(['author_id'])
             ->from(['a' => 'articles'])
+            ->order(['id' => 'DESC'])
             ->execute();
         $this->assertCount(2, $result);
         $expected = [
-            ['id' => 1, 'author_id' => 1],
+            ['id' => 3, 'author_id' => 1],
             ['id' => 2, 'author_id' => 3],
         ];
         $this->assertEquals($expected, $result->fetchAll('assoc'));