Exemplo n.º 1
0
        public DisplayResult(RunResult self, RunResult best)
            : base(self)
        {
            DurationDifference = self.Duration - best.Duration;

            var bestPerIteration = Math.Round((decimal)best.Duration / best.Iterations, 8);
            var selfPerIteration = Math.Round((decimal)Duration / Iterations, 8);
            PercentageDifference = bestPerIteration != 0m ? Math.Round(selfPerIteration / bestPerIteration, 6) : 0m;
        }
Exemplo n.º 2
0
 protected RunResult(RunResult other)
 {
     Iterations = other.Iterations;
     Duration = other.Duration;
     Description = other.Description;
     SubjectType = other.SubjectType;
     BenchmarkType = other.BenchmarkType;
     RunnerType = other.RunnerType;
     MemoryUsage = other.MemoryUsage;
 }