public getNodeMetrics ( PDepend\Source\AST\ASTArtifact $artifact ) : array(string=>mixed) | ||
$artifact | PDepend\Source\AST\ASTArtifact | |
return | array(string=>mixed) |
public function getNodeMetrics(ASTArtifact $artifact)
{
if (isset($this->nodeMetrics[$artifact->getId()])) {
return $this->nodeMetrics[$artifact->getId()];
}
return array();
}
/** * testAnalyzerNotCountsImplementedInterfaceMethodsAsOverwritten * * @return void */ public function testAnalyzerNotCountsImplementedInterfaceMethodsAsOverwritten() { $namespaces = self::parseCodeResourceForTest(); $class = $namespaces->current()->getClasses()->current(); $analyzer = new InheritanceAnalyzer(); $analyzer->analyze($namespaces); $metrics = $analyzer->getNodeMetrics($class); $this->assertEquals(1, $metrics['noom']); }