php-src/ext/spl/tests/SplFileObject_key_error002.phpt
George Peter Banyard 79a283240e
Revert "Fix GH-8563 Different results for seek() on SplFileObject and SplTempFileObject"
Although the fix is partially correct it also breaks long standing behaviour which has been produced since PHP 5.3.

This reverts commit 6f87a5c633.
2022-07-05 21:28:59 +01:00

22 lines
345 B
PHP

--TEST--
SPL: SplFileObject::key error
--CREDITS--
Ricardo Oedietram <ricardo@odracir.nl>
Erwin Poeze <erwin.poeze@gmail.com>
#PFZ June PHP TestFest 2012
--FILE--
<?php
//line 2
//line 3
//line 4
//line 5
$s = new SplFileObject(__FILE__);
$s->seek(120);
$s->next();
var_dump($s->key());
var_dump($s->valid());
?>
--EXPECT--
int(13)
bool(false)