/** * {@inheritdoc} */ public function resolve($className) { foreach ($this->resolvers as $resolver) { try { /* @var ResolverInterface $resolver */ return $resolver->resolve($className); } catch (\Exception $exception) { } } throw NotFoundException::handlerMethodNameForObject($className); }
/** * Test handlerMethodNameForObject method. */ public function testMethodNameForObject() { $this->given($exception = NotFoundException::handlerMethodNameForObject('bar'))->then()->variable($exception->getPrevious())->isNull(); }