067ff322f3a62e23d2748278e17bad7030dc5b90
[yaffs-website] / vendor / mikey179 / vfsStream / src / test / php / org / bovigo / vfs / vfsStreamWrapperStreamSelectTestCase.php
1 <?php
2 /**
3  * This file is part of vfsStream.
4  *
5  * For the full copyright and license information, please view the LICENSE
6  * file that was distributed with this source code.
7  *
8  * @package  org\bovigo\vfs
9  */
10 namespace org\bovigo\vfs;
11 /**
12  * Test for org\bovigo\vfs\vfsStreamWrapper.
13  *
14  * @since  0.9.0
15  * @group  issue_3
16  */
17 class vfsStreamWrapperSelectStreamTestCase extends \PHPUnit_Framework_TestCase
18 {
19     /**
20      * @test
21      * @expectedException \PHPUnit_Framework_Error
22      */
23     public function selectStream()
24     {
25         $root = vfsStream::setup();
26         $file = vfsStream::newFile('foo.txt')->at($root)->withContent('testContent');
27
28         $fp = fopen(vfsStream::url('root/foo.txt'), 'rb');
29         $readarray   = array($fp);
30         $writearray  = array();
31         $exceptarray = array();
32         stream_select($readarray, $writearray, $exceptarray, 1);
33     }
34 }