public static void Generate(BenchmarkComparison comparison) { string outputPath = Path.Combine( Path.GetDirectoryName(comparison.FilePath), $"report-{comparison.Type}"); Clean(outputPath); Generate(comparison, outputPath); }
static void Main() { ILookup <string, Benchmark> benchmarksByType = Benchmark.FindAll(CurrentDirectory) .ToLookup(benchmark => benchmark.Type); foreach (var benchmarks in benchmarksByType) { string type = benchmarks.Key; Console.WriteLine($"Generate comparison for benchmarks of type '{type}'..."); var fileName = Path.Combine(CurrentDirectory, $"{type}_comparison.csv"); var comparison = BenchmarkComparison.Generate(benchmarks, type, fileName); Console.WriteLine($"Generating report for benchmarks of type '{type}'..."); Report.Generate(comparison); } Console.WriteLine("Press any key to continue..."); Console.ReadKey(); }
private static void Generate(BenchmarkComparison comparison, string outputPath) { Process .Start("jmeter.bat", $"-g \"{comparison.FilePath}\" -o \"{outputPath}\"") .WaitForExit(); }