diff options
author | Andrey Andreev <narf@bofh.bg> | 2012-05-25 01:17:49 +0200 |
---|---|---|
committer | Andrey Andreev <narf@bofh.bg> | 2012-05-25 01:17:49 +0200 |
commit | 0174d84401b5c5996115a4a6193161f1dab96de2 (patch) | |
tree | 79660fc7e3c5d43702862ac588c2337f513ad69c /tests/codeigniter/database/query_builder | |
parent | 59d6b4fc4f4d7d5265b59cfd8c0f68f885083f69 (diff) |
Alter LIKE escaping tests again
Diffstat (limited to 'tests/codeigniter/database/query_builder')
-rw-r--r-- | tests/codeigniter/database/query_builder/escape_test.php | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/codeigniter/database/query_builder/escape_test.php b/tests/codeigniter/database/query_builder/escape_test.php index 96fbd078b..9df82c2d0 100644 --- a/tests/codeigniter/database/query_builder/escape_test.php +++ b/tests/codeigniter/database/query_builder/escape_test.php @@ -23,7 +23,10 @@ class Escape_test extends CI_TestCase { public function test_escape_like_percent_sign() { $string = $this->db->escape_like_str('\%foo'); - $res = $this->db->select('value')->from('misc')->like('key', $string, 'after')->get(); + $this->db->select('value'); + $this->db->from('misc'); + $this->db->like('key', $string, 'after'); + $res = $this->db->get(); // Check the result $this->assertEquals(1, count($res->result_array())); @@ -38,6 +41,10 @@ class Escape_test extends CI_TestCase { { $string = $this->db->escape_like_str('\\'); $res = $this->db->select('value')->from('misc')->like('key', $string, 'after')->get(); + $this->db->select('value'); + $this->db->from('misc'); + $this->db->like('key', $string, 'after'); + $res = $this->db->get(); // Check the result $this->assertEquals(2, count($res->result_array())); |