-
-
Notifications
You must be signed in to change notification settings - Fork 844
Expand file tree
/
Copy pathBenchmarkConfig.cs
More file actions
24 lines (18 loc) · 778 Bytes
/
BenchmarkConfig.cs
File metadata and controls
24 lines (18 loc) · 778 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Copyright (c) Autofac Project. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.
using System.Globalization;
using BenchmarkDotNet.Configs;
using BenchmarkDotNet.Diagnosers;
namespace Autofac.Benchmarks;
internal class BenchmarkConfig : ManualConfig
{
private const string BenchmarkArtifactsFolder = "BenchmarkDotNet.Artifacts";
internal BenchmarkConfig()
{
Add(DefaultConfig.Instance);
var rootFolder = AppContext.BaseDirectory;
var runFolder = DateTime.UtcNow.ToString("dd-MM-yyyy_hh-MM-ss", CultureInfo.InvariantCulture);
ArtifactsPath = Path.Combine(rootFolder, BenchmarkArtifactsFolder, runFolder);
AddDiagnoser(MemoryDiagnoser.Default);
}
}