Example #1
0
 /**
  * Generates and returns report
  *
  * @param int $startRevision First revision to work on
  * @param int $endRevision   Last revision to work on
  * @return VcsStats_Report Report
  */
 public function getReport($startRevision, $endRevision)
 {
     $report = new VcsStats_Report();
     $summarySection = new VcsStats_Report_Section();
     $report->addSection($summarySection);
     $summarySection->addElement($this->_computeRevisionsCountByAuthor($startRevision, $endRevision));
     return $report;
 }
Example #2
0
 public function testGetSections()
 {
     $report = new VcsStats_Report('Subversion', 'http://svn.example.com/repository/');
     $section1 = new VcsStats_Report_Section();
     $report->addSection($section1);
     $section2 = new VcsStats_Report_Section();
     $report->addSection($section2);
     $section3 = new VcsStats_Report_Section();
     $report->addSection($section3);
     $this->assertSame(array($section1, $section2, $section3), $report->getSections());
 }