summaryrefslogtreecommitdiff
path: root/ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt')
-rw-r--r--ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt15
1 files changed, 15 insertions, 0 deletions
diff --git a/ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt b/ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt
new file mode 100644
index 0000000..76ee2f5
--- /dev/null
+++ b/ext/spl/tests/SplFixedArray_offsetExists_invalid_parameter.phpt
@@ -0,0 +1,15 @@
+--TEST--
+SPL FixedArray offsetExists throws error only one parameter
+--CREDITS--
+PHPNW TestFest 2009 - Ben Longden
+--FILE--
+<?php
+$array = new SplFixedArray(5);
+$a = $array->offsetExists();
+if(is_null($a)) {
+ echo 'PASS';
+}
+?>
+--EXPECTF--
+Warning: SplFixedArray::offsetExists() expects exactly 1 parameter, 0 given in %s on line %d
+PASS