cvs: pecl /ibm_db2/tests test_045.phpt test_198.phpt
| From: | Kellen Bombardier | Date: | Wed, 05 Sep 2007 20:21:31 +0000 |
| Subject: | cvs: pecl /ibm_db2/tests test_045.phpt test_198.phpt | ||
| Groups: | php.pecl.cvs | ||
| Request: | Send a blank email to pecl-cvs+get-8514@lists.php.net to get a copy of this message | ||
kfbombar Wed Sep 5 20:21:31 2007 UTC
Modified files:
/pecl/ibm_db2/tests test_045.phpt test_198.phpt
Log:
Modifying tests that fetch binary data
http://cvs.php.net/viewvc.cgi/pecl/ibm_db2/tests/test_045.phpt?r1=1.4&r2=1.5&diff_format=u
Index: pecl/ibm_db2/tests/test_045.phpt
diff -u pecl/ibm_db2/tests/test_045.phpt:1.4 pecl/ibm_db2/tests/test_045.phpt:1.5
--- pecl/ibm_db2/tests/test_045.phpt:1.4 Mon Feb 12 19:53:48 2007
+++ pecl/ibm_db2/tests/test_045.phpt Wed Sep 5 20:21:31 2007
@@ -1,5 +1,5 @@
--TEST--
-IBM-DB2: db2_fetch_array() - one row binary data
+IBM-DB2: db2_fetch_array() - binary data
--SKIPIF--
<?php require_once('skipif.inc'); ?>
--FILE--
@@ -27,5 +27,13 @@
echo "The files are not the same...bad.";
}
+$result = db2_exec($conn, "select photo_format, picture, length(picture) from
emp_photo");
+$count = 0;
+while ($row = db2_fetch_array($result)) {
+ $count++;
+}
+
+echo "\nIterated over $count rows.";
--EXPECT--
The files are the same...good.
+Iterated over 8 rows.
\ No newline at end of file
http://cvs.php.net/viewvc.cgi/pecl/ibm_db2/tests/test_198.phpt?r1=1.1&r2=1.2&diff_format=u
Index: pecl/ibm_db2/tests/test_198.phpt
diff -u pecl/ibm_db2/tests/test_198.phpt:1.1 pecl/ibm_db2/tests/test_198.phpt:1.2
--- pecl/ibm_db2/tests/test_198.phpt:1.1 Mon Feb 12 19:54:53 2007
+++ pecl/ibm_db2/tests/test_198.phpt Wed Sep 5 20:21:31 2007
@@ -35,7 +35,7 @@
$drop = 'DROP TABLE blob_stream';
$result = @db2_exec( $conn, $drop );
- $create = 'CREATE TABLE blob_stream (id INTEGER, my_blob CLOB)';
+ $create = 'CREATE TABLE blob_stream (id INTEGER, my_blob BLOB)';
$result = db2_exec( $conn, $create );
$variable = "";
@@ -66,11 +66,17 @@
Loop 4: S IS A
Loop 5: CLOB
Loop 6: TEST.
-Loop 0: THIS I
-Loop 1: S A BL
-Loop 2: OB TES
-Loop 3: T. THI
-Loop 4: S IS A
-Loop 5: BLOB
-Loop 6: TEST.
-
+Loop 0: 544849
+Loop 1: 532049
+Loop 2: 532041
+Loop 3: 20424C
+Loop 4: 4F4220
+Loop 5: 544553
+Loop 6: 542E20
+Loop 7: 544849
+Loop 8: 532049
+Loop 9: 532041
+Loop 10: 20424C
+Loop 11: 4F4220
+Loop 12: 544553
+Loop 13: 542E