public void GetCollectionTest()
        {
            List <double[]> collection      = ChartSeriesHelper.GetCollection(today, 100, history, ReturnSeriesOf.CaloriesBurnt);
            int             numberOfRecords = 100 / 7;

            Assert.IsTrue(collection.Count == numberOfRecords);

            collection = ChartSeriesHelper.GetCollection(today, 100, history, ReturnSeriesOf.CaloriesPerMin);
            foreach (double[] series in collection)
            {
                Assert.IsTrue(series.Where(x => x > 20).Count() == 0);
            }
        }
        public void GetAverageTest()
        {
            List <double[]> collection = ChartSeriesHelper.GetCollection(today, TestSettings.rangeInDays, history, ReturnSeriesOf.CaloriesBurnt);

            Random r        = new Random();
            int    index    = r.Next(1439);
            double avgIndex = new double();

            foreach (double[] series in collection)
            {
                avgIndex += series[index];
            }
            avgIndex = avgIndex / collection.Count;

            double[] average = ChartSeriesHelper.GetAverage(collection);

            Assert.IsTrue(IsCalories(average));
            Assert.IsFalse(IsCalsPerMin(average));

            Assert.IsTrue(average[index] == avgIndex);
        }