|
@@ 39-44 (lines=6) @@
|
| 36 |
|
$this->assertEquals(count($ids), $count); |
| 37 |
|
$this->assertInternalType("int", $count); |
| 38 |
|
//test with `having` |
| 39 |
|
if (DB::get_conn() instanceof MySQLDatabase) { |
| 40 |
|
$qry->setHaving('"Date" > 2012-02-01'); |
| 41 |
|
$count = $qry->count('"SQLSelectTest_DO"."ID"'); |
| 42 |
|
$this->assertEquals(1, $count); |
| 43 |
|
$this->assertInternalType("int", $count); |
| 44 |
|
} |
| 45 |
|
} |
| 46 |
|
public function testUnlimitedRowCount() { |
| 47 |
|
//basic counting |
|
@@ 59-64 (lines=6) @@
|
| 56 |
|
$this->assertEquals(2, $count); |
| 57 |
|
$this->assertInternalType("int", $count); |
| 58 |
|
//test with `having` |
| 59 |
|
if (DB::get_conn() instanceof MySQLDatabase) { |
| 60 |
|
$qry->setHaving('"Date" > 2012-02-01'); |
| 61 |
|
$count = $qry->unlimitedRowCount('"SQLSelectTest_DO"."ID"'); |
| 62 |
|
$this->assertEquals(1, $count); |
| 63 |
|
$this->assertInternalType("int", $count); |
| 64 |
|
} |
| 65 |
|
} |
| 66 |
|
|
| 67 |
|
public function testEmptyQueryReturnsNothing() { |