From: Christopher Jones Date: Mon, 1 Mar 2010 20:33:18 +0000 (+0000) Subject: Improve basic code coverage X-Git-Tag: php-5.2.14RC1~124 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c21a9f21bbfcaed00db8695f678125d48cf831a5;p=php Improve basic code coverage --- diff --git a/ext/dba/tests/clean.inc b/ext/dba/tests/clean.inc new file mode 100644 index 0000000000..7c53e7e61f --- /dev/null +++ b/ext/dba/tests/clean.inc @@ -0,0 +1,5 @@ + diff --git a/ext/dba/tests/dba010.phpt b/ext/dba/tests/dba010.phpt new file mode 100644 index 0000000000..183562dc32 --- /dev/null +++ b/ext/dba/tests/dba010.phpt @@ -0,0 +1,41 @@ +--TEST-- +DBA with array keys +--SKIPIF-- + +--FILE-- + +--EXPECTF-- +database handler: flatfile +6YYYYYY \ No newline at end of file diff --git a/ext/dba/tests/dba_optimize.phpt b/ext/dba/tests/dba_optimize.phpt new file mode 100644 index 0000000000..334a705fd7 --- /dev/null +++ b/ext/dba/tests/dba_optimize.phpt @@ -0,0 +1,45 @@ +--TEST-- +DBA Optimize Test +--SKIPIF-- +--FILE-- + +===DONE=== + +--EXPECTF-- +database handler: flatfile +2YY + +Warning: Wrong parameter count for dba_optimize() in %sdba_optimize.php on line %d +NULL + +Warning: dba_optimize(): supplied argument is not a valid DBA identifier resource in %sdba_optimize.php on line %d +bool(false) +bool(true) +===DONE=== diff --git a/ext/dba/tests/dba_split.phpt b/ext/dba/tests/dba_split.phpt new file mode 100644 index 0000000000..9488992588 --- /dev/null +++ b/ext/dba/tests/dba_split.phpt @@ -0,0 +1,79 @@ +--TEST-- +DBA Split Test +--SKIPIF-- +--FILE-- + +===DONE=== + +--EXPECTF-- +Warning: Wrong parameter count for dba_key_split() in %sdba_split.php on line %d +NULL +array(2) { + [0]=> + %unicode|string%(0) "" + [1]=> + %unicode|string%(1) "1" +} +bool(false) +array(2) { + [0]=> + %unicode|string%(0) "" + [1]=> + %unicode|string%(0) "" +} +array(2) { + [0]=> + %unicode|string%(0) "" + [1]=> + %unicode|string%(5) "name1" +} +array(2) { + [0]=> + %unicode|string%(0) "" + [1]=> + %unicode|string%(5) "[key1" +} +array(2) { + [0]=> + %unicode|string%(4) "key1" + [1]=> + %unicode|string%(0) "" +} +array(2) { + [0]=> + %unicode|string%(0) "" + [1]=> + %unicode|string%(5) "key1]" +} +array(2) { + [0]=> + %unicode|string%(4) "key1" + [1]=> + %unicode|string%(5) "name1" +} +array(2) { + [0]=> + %unicode|string%(4) "key1" + [1]=> + %unicode|string%(16) "name1[key2]name2" +} +array(2) { + [0]=> + %unicode|string%(4) "key1" + [1]=> + %unicode|string%(5) "name1" +} +===DONE=== diff --git a/ext/dba/tests/dba_sync.phpt b/ext/dba/tests/dba_sync.phpt new file mode 100644 index 0000000000..7c63d2e75d --- /dev/null +++ b/ext/dba/tests/dba_sync.phpt @@ -0,0 +1,45 @@ +--TEST-- +DBA Sync Test +--SKIPIF-- +--FILE-- + +===DONE=== + +--EXPECTF-- +database handler: flatfile +2YY + +Warning: Wrong parameter count for dba_sync() in %sdba_sync.php on line %d +NULL + +Warning: dba_sync(): supplied argument is not a valid DBA identifier resource in %sdba_sync.php on line %d +bool(false) +bool(true) +===DONE===