summaryrefslogtreecommitdiff
path: root/ext/spl/tests/SplFileObject_rewind_error001.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/spl/tests/SplFileObject_rewind_error001.phpt')
-rw-r--r--ext/spl/tests/SplFileObject_rewind_error001.phpt18
1 files changed, 18 insertions, 0 deletions
diff --git a/ext/spl/tests/SplFileObject_rewind_error001.phpt b/ext/spl/tests/SplFileObject_rewind_error001.phpt
new file mode 100644
index 0000000..bdb3301
--- /dev/null
+++ b/ext/spl/tests/SplFileObject_rewind_error001.phpt
@@ -0,0 +1,18 @@
+--TEST--
+SPL: SplFileObject::rewind() with a parameter.
+--CREDITS--
+Ricardo Oedietram <ricardo@odracir.nl>
+Erwin Poeze <erwin.poeze@gmail.com>
+#PFZ June PHP TestFest 2012
+--FILE--
+<?php
+
+file_put_contents('testdata.csv', 'eerste;tweede;derde');
+
+$fo = new SplFileObject('testdata.csv');
+
+$fo->rewind( "invalid" );
+
+?>
+--EXPECTF--
+Warning: SplFileObject::rewind() expects exactly 0 parameters, 1 given in %s on line %d