summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYasuo Ohgaki <yohgaki@php.net>2013-08-02 09:52:08 +0900
committerYasuo Ohgaki <yohgaki@php.net>2013-08-02 09:52:08 +0900
commitcb13f8318b39f72798c3756dcfe55daae4c932e2 (patch)
tree6c283bbc98a0ac7fb2552359552ced3f2a730bd2
parent4590070f31bf93b351a5c2b0b023479265477a60 (diff)
downloadphp-git-cb13f8318b39f72798c3756dcfe55daae4c932e2.tar.gz
Add user contributed test. Bug #61748
-rw-r--r--ext/pdo_sqlite/tests/pdo_sqlite_createfunction_002.phpt17
1 files changed, 17 insertions, 0 deletions
diff --git a/ext/pdo_sqlite/tests/pdo_sqlite_createfunction_002.phpt b/ext/pdo_sqlite/tests/pdo_sqlite_createfunction_002.phpt
new file mode 100644
index 0000000000..a1d890ac1b
--- /dev/null
+++ b/ext/pdo_sqlite/tests/pdo_sqlite_createfunction_002.phpt
@@ -0,0 +1,17 @@
+--TEST--
+PDO_sqlite: Testing sqliteCreateFunction() produces warning when
+un-callable function passed
+--CREDITS--
+Chris MacPherson chris@kombine.co.uk
+--SKIPIF--
+<?php if (!extension_loaded('pdo_sqlite')) print 'skip not loaded'; ?>
+--FILE--
+<?php
+
+$db = new PDO( 'sqlite::memory:');
+
+$db->sqliteCreateFunction('bar-alias', 'bar');
+
+?>
+--EXPECTF--
+Warning: PDO::sqliteCreateFunction(): function 'bar' is not callable in %s on line %d