public function testGetFunctions()
 {
     $expectedFunctions = array('resource_granted' => 'checkResourceIsGranted');
     $actualFunctions = $this->twigExtension->getFunctions();
     $this->assertSameSize($expectedFunctions, $actualFunctions);
     foreach ($expectedFunctions as $twigFunction => $internalMethod) {
         $this->assertArrayHasKey($twigFunction, $actualFunctions);
         $this->assertInstanceOf('\\Twig_Function_Method', $actualFunctions[$twigFunction]);
         $this->assertAttributeEquals($internalMethod, 'method', $actualFunctions[$twigFunction]);
     }
 }
 public function testGetFunctions()
 {
     $expectedFunctions = array('resource_granted' => 'checkResourceIsGranted', 'format_share_scopes' => 'formatShareScopes', 'oro_share_count' => 'getShareCount', 'oro_shared_with_name' => 'getSharedWithName');
     $actualFunctions = $this->twigExtension->getFunctions();
     $this->assertSameSize($expectedFunctions, $actualFunctions);
     foreach ($expectedFunctions as $twigFunction => $internalMethod) {
         $this->assertArrayHasKey($twigFunction, $actualFunctions);
         $this->assertInstanceOf('\\Twig_Function_Method', $actualFunctions[$twigFunction]);
         $this->assertAttributeEquals($internalMethod, 'method', $actualFunctions[$twigFunction]);
     }
 }