public function testGoodGetResourceTypeHandler() { $classes = ['bar' => 'AuthBucket\\OAuth2\\Tests\\ResourceType\\BarResourceTypeHandler']; $factory = new ResourceTypeHandlerFactory($this->app, $this->app['authbucket_oauth2.model_manager.factory'], $classes); $handler = $factory->getResourceTypeHandler('bar'); $this->assertSame($factory->getResourceTypeHandlers(), $classes); }
public function testGoodGetResourceTypeHandler() { $classes = array('bar' => 'AuthBucket\\Bundle\\OAuth2Bundle\\Tests\\ResourceType\\BarResourceTypeHandler'); $factory = new ResourceTypeHandlerFactory($this->get('http_kernel'), $this->get('authbucket_oauth2.model_manager.factory'), $classes); $handler = $factory->getResourceTypeHandler('bar'); $this->assertEquals($factory->getResourceTypeHandlers(), $classes); }