protected function setUp() { // Register the DREST annotations \Drest\Mapping\Driver\AnnotationDriver::registerAnnotations(); // Register the ORM annotations \Doctrine\Common\Annotations\AnnotationRegistry::registerFile(__DIR__ . '/../../vendor/doctrine/orm/lib/Doctrine/ORM/Mapping/Driver/DoctrineAnnotations.php'); }
protected function setUp() { \Drest\Mapping\Driver\AnnotationDriver::registerAnnotations(); }
/** * Static call to create the Drest Manager instance * * @param EntityManager $em * @param Configuration $config * @param Event\Manager $eventManager * @return Manager $manager */ public static function create(EntityManager $em, Configuration $config, Event\Manager $eventManager = null) { // Register the annotations classes Mapping\Driver\AnnotationDriver::registerAnnotations(); if ($eventManager === null) { $eventManager = new Event\Manager(); } return new self($em, $config, $eventManager); }