X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fpsy%2Fpsysh%2Ftest%2FReadline%2FLibeditTest.php;h=2d7be2889ae40ce2da2bf542bee900f01b970700;hp=44a06c61fe69d54a091f53c42394cca457bbc5c0;hb=0bf8d09d2542548982e81a441b1f16e75873a04f;hpb=74df008bdbb3a11eeea356744f39b802369bda3c diff --git a/vendor/psy/psysh/test/Readline/LibeditTest.php b/vendor/psy/psysh/test/Readline/LibeditTest.php index 44a06c61f..2d7be2889 100644 --- a/vendor/psy/psysh/test/Readline/LibeditTest.php +++ b/vendor/psy/psysh/test/Readline/LibeditTest.php @@ -23,20 +23,20 @@ class LibeditTest extends \PHPUnit\Framework\TestCase $this->markTestSkipped('Libedit not enabled'); } - $this->historyFile = tempnam(sys_get_temp_dir(), 'psysh_test_history'); - if (false === file_put_contents($this->historyFile, "_HiStOrY_V2_\n")) { + $this->historyFile = \tempnam(\sys_get_temp_dir(), 'psysh_test_history'); + if (false === \file_put_contents($this->historyFile, "_HiStOrY_V2_\n")) { $this->fail('Unable to write history file: ' . $this->historyFile); } // Calling readline_read_history before readline_clear_history // avoids segfault with PHP 5.5.7 & libedit v3.1 - readline_read_history($this->historyFile); - readline_clear_history(); + \readline_read_history($this->historyFile); + \readline_clear_history(); } public function tearDown() { - if (is_file($this->historyFile)) { - unlink($this->historyFile); + if (\is_file($this->historyFile)) { + \unlink($this->historyFile); } } @@ -94,7 +94,7 @@ class LibeditTest extends \PHPUnit\Framework\TestCase public function testListHistory() { $readline = new Libedit($this->historyFile); - file_put_contents( + \file_put_contents( $this->historyFile, "This is an entry\n\0This is a comment\nThis is an entry\0With a comment\n", FILE_APPEND @@ -113,7 +113,7 @@ class LibeditTest extends \PHPUnit\Framework\TestCase public function testLinebreaksSupport() { $readline = new Libedit($this->historyFile); - file_put_contents( + \file_put_contents( $this->historyFile, "foo\rbar\nbaz\r\nw00t", FILE_APPEND