summaryrefslogtreecommitdiffstats
path: root/tests/codeigniter/database/query_builder/where_test.php
diff options
context:
space:
mode:
Diffstat (limited to 'tests/codeigniter/database/query_builder/where_test.php')
-rw-r--r--tests/codeigniter/database/query_builder/where_test.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/codeigniter/database/query_builder/where_test.php b/tests/codeigniter/database/query_builder/where_test.php
index 46a7fa2eb..8a7a09ddb 100644
--- a/tests/codeigniter/database/query_builder/where_test.php
+++ b/tests/codeigniter/database/query_builder/where_test.php
@@ -36,7 +36,7 @@ class Where_test extends CI_TestCase {
public function test_where_custom_key_value()
{
$jobs = $this->db->where('id !=', 1)->get('job')->result_array();
- $this->assertEquals(3, count($jobs));
+ $this->assertCount(3, $jobs);
}
// ------------------------------------------------------------------------
@@ -49,7 +49,7 @@ class Where_test extends CI_TestCase {
$where = array('id >' => 2, 'name !=' => 'Accountant');
$jobs = $this->db->where($where)->get('job')->result_array();
- $this->assertEquals(1, count($jobs));
+ $this->assertCount(1, $jobs);
// Should be Musician
$job = current($jobs);
@@ -66,7 +66,7 @@ class Where_test extends CI_TestCase {
$where = "id > 2 AND name != 'Accountant'";
$jobs = $this->db->where($where)->get('job')->result_array();
- $this->assertEquals(1, count($jobs));
+ $this->assertCount(1, $jobs);
// Should be Musician
$job = current($jobs);
@@ -85,7 +85,7 @@ class Where_test extends CI_TestCase {
->get('job')
->result_array();
- $this->assertEquals(3, count($jobs));
+ $this->assertCount(3, $jobs);
$this->assertEquals('Developer', $jobs[0]['name']);
$this->assertEquals('Politician', $jobs[1]['name']);
$this->assertEquals('Musician', $jobs[2]['name']);
@@ -102,7 +102,7 @@ class Where_test extends CI_TestCase {
->get('job')
->result_array();
- $this->assertEquals(2, count($jobs));
+ $this->assertCount(2, $jobs);
$this->assertEquals('Politician', $jobs[0]['name']);
$this->assertEquals('Accountant', $jobs[1]['name']);
}
@@ -118,7 +118,7 @@ class Where_test extends CI_TestCase {
->get('job')
->result_array();
- $this->assertEquals(2, count($jobs));
+ $this->assertCount(2, $jobs);
$this->assertEquals('Developer', $jobs[0]['name']);
$this->assertEquals('Musician', $jobs[1]['name']);
}
@@ -131,4 +131,4 @@ class Where_test extends CI_TestCase {
$sql = $this->db->where('foo', $input)->get_compiled_select('dummy');
$this->assertEquals("'".$input."'", substr($sql, -20));
}
-} \ No newline at end of file
+}