Windows-powershell / PowerShell-master /test /perf /dotnet-tools /ResultsComparer /CommandLineOptions.cs
| // Licensed to the .NET Foundation under one or more agreements. | |
| // The .NET Foundation licenses this file to you under the MIT license. | |
| // See the LICENSE file in the project root for more information. | |
| using System.Collections.Generic; | |
| using System.IO; | |
| using CommandLine; | |
| using CommandLine.Text; | |
| namespace ResultsComparer | |
| { | |
| public class CommandLineOptions | |
| { | |
| [] | |
| public string BasePath { get; set; } | |
| [] | |
| public string DiffPath { get; set; } | |
| [] | |
| public string StatisticalTestThreshold { get; set; } | |
| [] | |
| public string NoiseThreshold { get; set; } | |
| [] | |
| public int? TopCount { get; set; } | |
| [] | |
| public FileInfo CsvPath { get; set; } | |
| [] | |
| public FileInfo XmlPath { get; set; } | |
| [] | |
| public IEnumerable<string> Filters { get; set; } | |
| [] | |
| public static IEnumerable<Example> Examples | |
| { | |
| get | |
| { | |
| yield return new Example(@"Compare the results stored in 'C:\results\win' (base) vs 'C:\results\unix' (diff) using 5% threshold.", | |
| new CommandLineOptions { BasePath = @"C:\results\win", DiffPath = @"C:\results\unix", StatisticalTestThreshold = "5%" }); | |
| yield return new Example(@"Compare the results stored in 'C:\results\win' (base) vs 'C:\results\unix' (diff) using 5% threshold and show only top/bottom 10 results.", | |
| new CommandLineOptions { BasePath = @"C:\results\win", DiffPath = @"C:\results\unix", StatisticalTestThreshold = "5%", TopCount = 10 }); | |
| yield return new Example(@"Compare the results stored in 'C:\results\win' (base) vs 'C:\results\unix' (diff) using 5% threshold and 0.5ns noise filter.", | |
| new CommandLineOptions { BasePath = @"C:\results\win", DiffPath = @"C:\results\unix", StatisticalTestThreshold = "5%", NoiseThreshold = "0.5ns" }); | |
| yield return new Example(@"Compare the System.Math benchmark results stored in 'C:\results\ubuntu16' (base) vs 'C:\results\ubuntu18' (diff) using 5% threshold.", | |
| new CommandLineOptions { Filters = new[] { "System.Math*" }, BasePath = @"C:\results\win", DiffPath = @"C:\results\unix", StatisticalTestThreshold = "5%" }); | |
| } | |
| } | |
| } | |
| } | |