public void ResultStatisticsController_PostNotNull_True()
        {
            using (var controller = new ResultStatisticsController())
            {
                using (var resultStatistics = new ResultStatistics())
                {
                    var result = controller.PredictResult(resultStatistics) as ViewResult;

                    Assert.IsNotNull(result);
                }
            }
        }
Esempio n. 2
0
        public ResultStatistics GetStatistics()
        {
            var logs = this._logger.GetLogs();

            var resultStats = new ResultStatistics
            {
                MaxRequest = logs.Max(x => Convert.ToInt32(x.Size)).ToString(),
                MinRequest = logs.Min(x => Convert.ToInt32(x.Size)).ToString(),
                AvgRequest = logs.Average(x => Convert.ToInt32(x.Size)).ToString(),
            };

            return(resultStats);
        }
Esempio n. 3
0
 public ActionResult PredictResult(ResultStatistics predictedResultStats)
 {
     return(View(predictedResultStats));
 }
Esempio n. 4
0
        // GET: ResultStatistics
        public ActionResult Index()
        {
            var resultsStats = new ResultStatistics();

            return(View(resultsStats));
        }