Kraken\_Unit\Filesystem\FilesystemTest::testApiReq_ThrowsException_WhenModelReadThrowsException PHP Method

testApiReq_ThrowsException_WhenModelReadThrowsException() public method

    public function testApiReq_ThrowsException_WhenModelReadThrowsException()
    {
        $path = 'path';
        $ex = null;
        $this->expect('read', [$path])->willThrow($expected = new Exception());
        try {
            $this->fs->req($path);
        } catch (Exception $ex) {
        }
        $this->assertInstanceOf(ReadException::class, $ex);
        $this->assertSame($expected, $ex->getPrevious());
    }
FilesystemTest