[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite/tests bug44327_2.phpt bug44327_3.phpt debugdumpparams_001.phpt pdo_sqlite_createaggregate.phpt pdo_sqlite_createfunction.phpt pdo_sqlite_lastinsertid.ph

2008-12-03 Thread Johannes Schlüter
johannesWed Dec  3 11:00:31 2008 UTC

  Modified files:  (Branch: PHP_5_3)
/php-src/ext/pdo_sqlite/tests   bug44327_2.phpt bug44327_3.phpt 
debugdumpparams_001.phpt 
pdo_sqlite_createaggregate.phpt 
pdo_sqlite_createfunction.phpt 
pdo_sqlite_lastinsertid.phpt 
pdo_sqlite_transaction.phpt 
  Log:
  MFH: Fix tests (use a in-memory database not a file called memory)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/bug44327_2.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/bug44327_2.phpt
diff -u php-src/ext/pdo_sqlite/tests/bug44327_2.phpt:1.1.2.2 
php-src/ext/pdo_sqlite/tests/bug44327_2.phpt:1.1.2.3
--- php-src/ext/pdo_sqlite/tests/bug44327_2.phpt:1.1.2.2Mon Nov  3 
21:49:34 2008
+++ php-src/ext/pdo_sqlite/tests/bug44327_2.phptWed Dec  3 11:00:31 2008
@@ -7,7 +7,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 
 $x = $db-query('select 1 as queryString');
 var_dump($x, $x-queryString);
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/bug44327_3.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/bug44327_3.phpt
diff -u php-src/ext/pdo_sqlite/tests/bug44327_3.phpt:1.1.2.2 
php-src/ext/pdo_sqlite/tests/bug44327_3.phpt:1.1.2.3
--- php-src/ext/pdo_sqlite/tests/bug44327_3.phpt:1.1.2.2Mon Nov  3 
23:44:38 2008
+++ php-src/ext/pdo_sqlite/tests/bug44327_3.phptWed Dec  3 11:00:31 2008
@@ -7,7 +7,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 
 $x = $db-query('select 1 as queryStringxx');
 $y = $x-fetch(PDO::FETCH_LAZY);
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt?r1=1.1.2.3r2=1.1.2.4diff_format=u
Index: php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt
diff -u php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt:1.1.2.3 
php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt:1.1.2.4
--- php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt:1.1.2.3   Wed Nov 
 5 23:40:38 2008
+++ php-src/ext/pdo_sqlite/tests/debugdumpparams_001.phpt   Wed Dec  3 
11:00:31 2008
@@ -7,7 +7,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 
 $x= $db-prepare('select :a, :b, ?');
 $x-bindValue(':a', 1, PDO::PARAM_INT);
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phpt
diff -u php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phpt:1.1.2.2 
php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phpt:1.1.2.3
--- php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phpt:1.1.2.2
Tue Dec  2 21:01:37 2008
+++ php-src/ext/pdo_sqlite/tests/pdo_sqlite_createaggregate.phptWed Dec 
 3 11:00:31 2008
@@ -3,7 +3,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 
 $db-query('CREATE TABLE IF NOT EXISTS foobar (id INT AUTO INCREMENT, name 
TEXT)');
 
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt
diff -u php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt:1.1.2.2 
php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt:1.1.2.3
--- php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt:1.1.2.2 Tue Dec 
 2 21:01:37 2008
+++ php-src/ext/pdo_sqlite/tests/pdo_sqlite_createfunction.phpt Wed Dec  3 
11:00:31 2008
@@ -3,7 +3,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 
 $db-query('CREATE TABLE IF NOT EXISTS foobar (id INT AUTO INCREMENT, name 
TEXT)');
 
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt
diff -u php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt:1.1.2.2 
php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt:1.1.2.3
--- php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt:1.1.2.2   Tue Dec 
 2 21:01:37 2008
+++ php-src/ext/pdo_sqlite/tests/pdo_sqlite_lastinsertid.phpt   Wed Dec  3 
11:00:31 2008
@@ -3,7 +3,7 @@
 --FILE--
 ?php
 
-$db = new pdo('sqlite:memory');
+$db = new pdo('sqlite::memory:');
 $db-query('CREATE TABLE IF NOT EXISTS foo (id INT AUTO INCREMENT, name 
TEXT)');
 $db-query('INSERT INTO foo VALUES (NULL, PHP)');
 $db-query('INSERT INTO foo VALUES (NULL, PHP6)');
http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/pdo_sqlite_transaction.phpt?r1=1.1.2.2r2=1.1.2.3diff_format=u
Index: php-src/ext/pdo_sqlite/tests/pdo_sqlite_transaction.phpt
diff -u 

[PHP-CVS] cvs: php-src(PHP_5_3) /ext/pdo_sqlite/tests bug44327_2.phpt

2008-11-03 Thread Felipe Pena
felipe  Mon Nov  3 21:49:34 2008 UTC

  Added files: (Branch: PHP_5_3)
/php-src/ext/pdo_sqlite/tests   bug44327_2.phpt 
  Log:
  - New test
  

http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_sqlite/tests/bug44327_2.phpt?view=markuprev=1.1
Index: php-src/ext/pdo_sqlite/tests/bug44327_2.phpt
+++ php-src/ext/pdo_sqlite/tests/bug44327_2.phpt
--TEST--
Bug #44327.2 (PDORow::queryString property  numeric offsets / Crash)
--SKIPIF--
?php
if (!extension_loaded('pdo_sqlite')) print 'skip not loaded';
?
--FILE--
?php

$db = new pdo('sqlite:memory');

$x = $db-query('select 1 as queryString');
var_dump($x, $x-queryString);

$y = $x-fetch();
var_dump($y, @$y-queryString);

print \n;

$x = $db-query('select 1 as queryString');
var_dump($x, $x-queryString);

$y = $x-fetch(PDO::FETCH_LAZY);
var_dump($y, $y-queryString);

?
--EXPECTF--
object(PDOStatement)#%d (1) {
  [queryString]=
  string(23) select 1 as queryString
}
string(23) select 1 as queryString
array(2) {
  [queryString]=
  string(1) 1
  [0]=
  string(1) 1
}
NULL

object(PDOStatement)#%d (1) {
  [queryString]=
  string(23) select 1 as queryString
}
string(23) select 1 as queryString
object(PDORow)#%d (1) {
  [queryString]=
  string(1) 1
}
string(1) 1



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php