1. We call the AfterInvocationManager with the method's return value as parameter 2. If we had a "run as" support, we would have to reset the security context 3. If a PermissionDeniedException was thrown we look for any an authentication entry point in the active tokens to redirect to authentication 4. Then the value is returned to the caller
Наследование: implements Neos\Flow\Security\Authorization\InterceptorInterface
 /**
  * @test
  */
 public function invokeReturnsTheResultPreviouslySetBySetResultIfTheMethodIsNotIntercepted()
 {
     $mockSecurityContext = $this->createMock(Security\Context::class);
     $mockAfterInvocationManager = $this->createMock(Security\Authorization\AfterInvocationManagerInterface::class);
     $theResult = new \ArrayObject(['some' => 'stuff']);
     $interceptor = new Security\Authorization\Interceptor\AfterInvocation($mockSecurityContext, $mockAfterInvocationManager);
     $interceptor->setResult($theResult);
     $this->assertSame($theResult, $interceptor->invoke());
 }