cvs: php-src /ext/pdo_mysql/tests pdo_mysql_stmt_fetch_serialize.phpt pdo_mysql_stmt_fetch_serialize_simple.phpt

From: Date: Fri, 10 Oct 2008 16:56:28 +0000
Subject: cvs: php-src /ext/pdo_mysql/tests pdo_mysql_stmt_fetch_serialize.phpt pdo_mysql_stmt_fetch_serialize_simple.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-53428@lists.php.net to get a copy of this message
felipe Fri Oct 10 16:56:28 2008 UTC Modified files: /php-src/ext/pdo_mysql/tests pdo_mysql_stmt_fetch_serialize.phpt pdo_mysql_stmt_fetch_serialize_simple.phpt Log: - Fixed tests http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt?r1=1.2&r2=1.3&diff_format=u Index: php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt diff -u php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt:1.2 php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt:1.3 --- php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt:1.2 Tue Jul 22 18:33:28 2008 +++ php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize.phpt Fri Oct 10 16:56:28 2008 @@ -130,13 +130,11 @@ } Using PDO::FETCH_CLASS|PDO::FETCH_SERIALIZE to fetch the object from DB and unserialize it... -myclass::__set(myobj, 'C:7:"myclass":19:{Data from serialize}') +myclass::unserialize('C:7:"myclass":19:{Data from serialize}') myclass::__construct(PDO shall not call __construct()) -object(myclass)#%d (2) { +object(myclass)#%d (1) { [u"myprotected":protected]=> unicode(19) "a protected propery" - [u"myobj"]=> - unicode(38) "C:7:"myclass":19:{Data from serialize}" } Using PDO::FETCH_CLASS to fetch the object from DB and unserialize it... @@ -148,4 +146,4 @@ [u"myobj"]=> unicode(38) "C:7:"myclass":19:{Data from serialize}" } -done! \ No newline at end of file +done! http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt?r1=1.1&r2=1.2&diff_format=u Index: php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt diff -u php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt:1.1 php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt:1.2 --- php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt:1.1 Mon Jul 21 13:05:51 2008 +++ php-src/ext/pdo_mysql/tests/pdo_mysql_stmt_fetch_serialize_simple.phpt Fri Oct 10 16:56:28 2008 @@ -89,10 +89,8 @@ } And now PDO using setFetchMode(PDO::FETCH:CLASS|PDO::FETCH_SERIALIZE) + fetch()... -myclass::__set('myobj', 'Data fetched from DB to be given to unserialize()') +myclass::unserialize('Data fetched from DB to be given to unserialize()') myclass::__construct('Called by PDO') - note that it must not be called when unserializing -object(myclass)#%d (1) { - ["myobj"]=> - string(49) "Data fetched from DB to be given to unserialize()" +object(myclass)#%d (0) { } -done! \ No newline at end of file +done!

« previous php.cvs (#53428) next »