cvs: pear /MDB2/tests MDB2_bugs_testcase.php

From: Date: Wed, 07 Apr 2004 21:12:50 +0000
Subject: cvs: pear /MDB2/tests MDB2_bugs_testcase.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-17998@lists.php.net to get a copy of this message
lsmith Wed Apr 7 17:12:50 2004 EDT Modified files: /pear/MDB2/tests MDB2_bugs_testcase.php Log: - expanded checking in bug #946 checking to also cover limit queries http://cvs.php.net/diff.php/pear/MDB2/tests/MDB2_bugs_testcase.php?r1=1.7&r2=1.8&ty=u Index: pear/MDB2/tests/MDB2_bugs_testcase.php diff -u pear/MDB2/tests/MDB2_bugs_testcase.php:1.7 pear/MDB2/tests/MDB2_bugs_testcase.php:1.8 --- pear/MDB2/tests/MDB2_bugs_testcase.php:1.7 Tue Mar 9 09:23:14 2004 +++ pear/MDB2/tests/MDB2_bugs_testcase.php Wed Apr 7 17:12:50 2004 @@ -310,7 +310,9 @@ $this->assertTrue(false, 'Error executing prepared query'.$result->getMessage()); } } + $this->db->freePrepared($prepared_query); + $this->db->setLimit(3, 1); $result = $this->db->query('SELECT * FROM users'); $numrows = $result->numRows(); while ($row = $result->fetchRow()) { @@ -318,9 +320,16 @@ $this->assertTrue(false, 'Error fetching a row'.$row->getMessage()); } } + $result->free(); + $result = $this->db->query('SELECT * FROM users'); + $numrows = $result->numRows(); + while ($row = $result->fetchRow()) { + if (MDB2::isError($row)) { + $this->assertTrue(false, 'Error fetching a row'.$row->getMessage()); + } + } $result->free(); - $this->db->freePrepared($prepared_query); } }

« previous php.pear.cvs (#17998) next »