]> granicus.if.org Git - php/commitdiff
add test to see if insert fails when key already exists
authorMarcus Boerger <helly@php.net>
Thu, 7 Nov 2002 14:18:42 +0000 (14:18 +0000)
committerMarcus Boerger <helly@php.net>
Thu, 7 Nov 2002 14:18:42 +0000 (14:18 +0000)
ext/dba/tests/dba_handler.inc

index e8bb97c1a0ed7591f2b700e760a3b17d0d6fde7f..87a77b7873aa760ef0ec00c86679fbd78177edb8 100644 (file)
@@ -34,6 +34,7 @@
        }
        if ($db_writer!==FALSE) {
                dba_insert("key number 6", "The 6th value", $db_writer);
+               @dba_insert("key number 6", "The 6th value inserted again would be an error", $db_writer);
                dba_replace("key2", "Content 2 replaced 2nd time", $db_writer);
                dba_delete("key4", $db_writer);
                echo dba_fetch("key2", $db_writer)."\n";