/** * @dataProvider dataStatistical */ public function testStatisctiaclData($expectedStats, $mockData) { $graphite = $this->mockFactory->getGraphiteClientMock(); $target = new Target($graphite, 'test.target', array(), array()); $graphite->expects($this->once())->method('getData')->will($this->returnValue($mockData)); $stats = $target->stats(); $this->assertEquals($expectedStats, $stats); }
/** * @deprecated */ public function getAvgTargetValue($target, $graphiteUrl, array $options, $nullAsZero = false) { $options['nullAsZero'] = (int) $nullAsZero; $target = new Target($this, $target, array(), $options); return $target->avg(); }