/** * */ 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()); }