for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of the Cubiche/Metadata component.
*
* Copyright (c) Cubiche
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Cubiche\Core\Metadata\Tests\Units\Driver;
use Cubiche\Core\Metadata\Exception\MappingException;
use Cubiche\Core\Metadata\Locator\DefaultFileLocator;
use Cubiche\Core\Metadata\Tests\Fixtures\Driver\YamlDriver;
* AbstractYamlDriverTests class.
* Generated by TestGenerator on 2017-05-16 at 13:17:21.
class AbstractYamlDriverTests extends DriverTestCase
{
* @return YamlDriver
protected function createDriver()
$mappingDirectory = __DIR__.'/../../Fixtures/mapping';
return new YamlDriver(
new DefaultFileLocator([
$mappingDirectory => 'Cubiche\Core\Metadata\Tests\Fixtures',
])
);
}
* Test loadMetadataForClass method.
public function testLoadMetadataForClass()
parent::testLoadMetadataForClass();
$this
->given($driver = $this->createDriver())
->then()
->exception(function () use ($driver) {
$driver->loadMetadataForClass('Cubiche\Core\Metadata\Tests\Fixtures\Venue');
})->isInstanceOf(MappingException::class)
;