public function testExtractDeliveryDataSet()
 {
     $dataSet = $this->statsService->extractDeliveryDataSet($this->subClass);
     $this->dataSet = $dataSet;
     $this->assertEqual($dataSet["nbExecutions"], 1);
     $this->assertEqual(count($dataSet["statisticsPerVariable"]), 1);
     $this->assertEqual(count($dataSet["statisticsPerVariable"]["GRADE"]), 6);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["sum"], 0.4);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["#"], 1);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["data"], array(0.4));
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["naturalid"], " (GRADE)");
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["avg"], 0.4);
     $this->assertEqual(count($dataSet["statisticsPerVariable"]["GRADE"]["splitData"]), 1);
     $this->assertEqual(count($dataSet["statisticsPerVariable"]["GRADE"]["splitData"][1]), 3);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["splitData"][1]["sum"], 0.4);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["splitData"][1]["avg"], 0.4);
     $this->assertEqual($dataSet["statisticsPerVariable"]["GRADE"]["splitData"][1]["#"], 1);
     $this->assertEqual($dataSet["statistics"]["sum"], 0.4);
     $this->assertEqual($dataSet["statistics"]["#"], 1);
     $this->assertEqual($dataSet["statistics"]["data"], array(0.4));
     $this->assertEqual(count($dataSet["statistics"]["splitData"]), 1);
     $this->assertEqual(count($dataSet["statistics"]["splitData"][1]), 3);
     $this->assertEqual($dataSet["statistics"]["splitData"][1]["sum"], 0.4);
     $this->assertEqual($dataSet["statistics"]["splitData"][1]["avg"], 0.4);
     $this->assertEqual($dataSet["statistics"]["splitData"][1]["#"], 1);
     $this->assertEqual($dataSet["statistics"]["avg"], 0.4);
 }
 /**
  * constructor
  *
  * @author Patrick Plichart, <*****@*****.**>
  */
 public function __construct()
 {
     parent::__construct();
     $this->service = taoResults_models_classes_StatisticsService::singleton();
     $this->defaultData();
     //TODO define a hook for implemeitng differently the report structure with an interface
     $this->reportService = taoResults_models_classes_ReportService::singleton();
 }