Cascade\Tests\Config\Loader\FileLoader\FileLoaderAbstractTest::testloadFileFromInvalidFile PHP Method

testloadFileFromInvalidFile() public method

Test loading an invalid file
    public function testloadFileFromInvalidFile()
    {
        // mocking the file system from a 'config_dir' base dir
        $root = vfsStream::setup('config_dir');
        // Adding an unreadable file (chmod 0000)
        vfsStream::newFile('config.yml', 00)->withContent("---\n" . "hidden_config: true")->at($root);
        // This will throw an exception because the file is not readable
        $this->mock->readFrom(vfsStream::url('config_dir/config.yml'));
        stream_wrapper_unregister(vfsStream::SCHEME);
    }