Lines Matching refs:wrapper
56 ->given($wrapper = new SUT())
57 ->when($result = $wrapper->stream_cast(STREAM_CAST_FOR_SELECT))
66 ->given($wrapper = new SUT())
67 ->when($result = $wrapper->stream_cast(STREAM_CAST_AS_STREAM))
77 $wrapper = new SUT(),
78 $this->openFile($wrapper)
80 ->when($result = $wrapper->stream_close())
84 ->variable($wrapper->getStream())
86 ->variable($wrapper->getStreamName())
94 $wrapper = new SUT(),
95 $this->openFile($wrapper, 'foo'),
96 fseek($wrapper->getStream(), 0, SEEK_SET)
98 ->when($result = $wrapper->stream_eof())
109 $wrapper = new SUT()
111 ->when($result = $wrapper->stream_eof())
121 $wrapper = new SUT(),
122 $this->openFile($wrapper)
124 ->when($result = $wrapper->stream_flush())
144 $wrapper = new SUT(),
145 $this->openFile($wrapper)
147 ->when($result = $wrapper->stream_lock($operation))
153 ->isIdenticalTo($wrapper->getStream())
189 $wrapper = new SUT()
191 ->when($result = $wrapper->stream_metadata($path, STREAM_META_TOUCH, $arguments))
230 $wrapper = new SUT()
232 ->when($result = $wrapper->stream_metadata('foo', $owner, $user))
264 $wrapper = new SUT()
266 ->when($result = $wrapper->stream_metadata('foo', $grp, $group))
298 $wrapper = new SUT()
300 ->when($result = $wrapper->stream_metadata('foo', STREAM_META_ACCESS, $mode))
316 $wrapper = new SUT()
318 ->when($result = $wrapper->stream_metadata('foo', $option, $mode))
335 $wrapper = new SUT(),
340 ->when($result = $wrapper->stream_open($path, $mode, $options, $openedPath))
352 ->isIdenticalTo($wrapper->getStream())
353 ->string($wrapper->getStreamName())
361 $wrapper = new SUT(),
366 ->when($result = $wrapper->stream_open($path, $mode, $options, $openedPath))
385 $wrapper = new SUT(),
390 ->when($result = $wrapper->stream_open($path, $mode, $options, $openedPath))
414 $wrapper = new SUT(),
416 $this->openFile($wrapper, str_repeat('@', $count))
418 ->when($result = $wrapper->stream_read($count))
424 ->isIdenticalTo($wrapper->getStream())
441 $wrapper = new SUT(),
442 $this->openFile($wrapper, 'foobar')
444 ->when($result = $wrapper->stream_seek($offset, $whence))
450 ->isIdenticalTo($wrapper->getStream())
455 ->integer(ftell($wrapper->getStream()));
491 $wrapper = new SUT(),
492 $this->openFile($wrapper)
494 ->when($result = $wrapper->stream_stat())
499 ->isIdenticalTo($wrapper->getStream());
511 $wrapper = new SUT(),
512 $this->openFile($wrapper, 'foo'),
513 $wrapper->stream_seek(2)
515 ->when($result = $wrapper->stream_tell())
521 ->isIdenticalTo($wrapper->getStream());
534 $wrapper = new SUT(),
535 $this->openFile($wrapper, 'foobar'),
538 ->when($result = $wrapper->stream_truncate($size))
544 ->isIdenticalTo($wrapper->getStream())
547 ->integer($wrapper->stream_tell())
549 ->let($wrapper->stream_seek(0, SEEK_END))
550 ->integer($wrapper->stream_tell())
564 $wrapper = new SUT(),
565 … $wrapper->stream_open('hoa://Test/Vfs/Foo?type=file', 'wb+', STREAM_USE_PATH, $openedPath),
568 ->when($result = $wrapper->stream_write($data))
574 ->isIdenticalTo($wrapper->getStream())
577 ->let($wrapper->stream_seek(0))
578 ->string($wrapper->stream_read(3))
586 $wrapper = new SUT(),
587 $this->openDirectory($wrapper)
589 ->when($result = $wrapper->dir_closedir())
593 ->variable($wrapper->getStream())
595 ->variable($wrapper->getStreamName())
608 $wrapper = new SUT(),
612 ->when($result = $wrapper->dir_opendir($path, $options))
618 ->resource($wrapper->getStream())
620 ->string($wrapper->getStreamName())
633 $wrapper = new SUT(),
637 ->when($result = $wrapper->dir_opendir($path, $options))
643 ->variable($wrapper->getStream())
645 ->variable($wrapper->getStreamName())
658 $wrapper = new SUT(),
659 $this->openDirectory($wrapper, ['Baz', 'Qux'])
661 ->when($result = $wrapper->dir_readdir())
666 ->isIdenticalTo($wrapper->getStream());
678 $wrapper = new SUT(),
679 $this->openDirectory($wrapper, ['Baz', 'Qux'])
681 ->when($result = $wrapper->dir_readdir())
686 ->isIdenticalTo($wrapper->getStream())
688 ->when($result = $wrapper->dir_readdir())
693 ->when($result = $wrapper->dir_readdir())
708 $wrapper = new SUT(),
709 $this->openDirectory($wrapper, ['Baz']),
710 $wrapper->dir_readdir()
712 ->when($result = $wrapper->dir_rewinddir())
717 ->when($result = $wrapper->dir_readdir())
722 ->isIdenticalTo($wrapper->getStream());
736 $wrapper = new SUT(),
737 $this->openDirectory($wrapper),
742 ->when($result = $wrapper->mkdir($path, $mode, $options))
764 $wrapper = new SUT(),
765 $this->openFile($wrapper),
769 ->when($result = $wrapper->rename($from, $to))
788 $wrapper = new SUT(),
789 $this->openDirectory($wrapper)
791 ->when($result = $wrapper->rmdir('hoa://Test/Vfs/Bar?type=directory', 0))
801 $wrapper = new SUT(),
802 $this->openFile($wrapper)
804 ->when($result = $wrapper->rmdir('hoa://Test/Vfs/Foo?type=file', 0))
814 $wrapper = new SUT(),
815 $this->openFile($wrapper)
817 ->when($result = $wrapper->unlink('hoa://Test/Vfs/Foo?type=file'))
827 $wrapper = new SUT(),
828 $this->openDirectory($wrapper)
830 ->when($result = $wrapper->unlink('hoa://Test/Vfs/Bar?type=directory'))
845 $wrapper = new SUT(),
846 $this->openFile($wrapper),
849 ->when($result = $wrapper->url_stat($path, 0))
880 $wrapper = new SUT(),
883 ->when(function () use ($wrapper, $path) {
884 $wrapper->url_stat($path, 0);
891 protected function openFile(SUT $wrapper, $content = '') argument
893 $wrapper->stream_open('hoa://Test/Vfs/Foo?type=file', 'wb+', STREAM_USE_PATH, $openedPath);
897 return $wrapper;
900 protected function openDirectory(SUT $wrapper, array $children = []) argument
902 $wrapper->dir_opendir('hoa://Test/Vfs/Bar?type=directory', 0);
908 return $wrapper;