From: Bjørn Erik Pedersen Date: Tue, 5 Dec 2017 15:17:11 +0000 (+0100) Subject: Use StopTimer in site benchmarks X-Git-Tag: v0.32~24 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=84805a68caca2f21a7a32f54ac4c1f6e0ada98ac;p=brevno-suite%2Fhugo Use StopTimer in site benchmarks --- diff --git a/hugolib/site_benchmark_test.go b/hugolib/site_benchmark_test.go index d7f30036..30720e7e 100644 --- a/hugolib/site_benchmark_test.go +++ b/hugolib/site_benchmark_test.go @@ -133,8 +133,9 @@ func BenchmarkSiteBuilding(b *testing.B) { func doBenchMarkSiteBuilding(conf siteBuildingBenchmarkConfig, b *testing.B) { b.Run(conf.String(), func(b *testing.B) { + b.StopTimer() sites := createHugoBenchmarkSites(b, b.N, conf) - b.ResetTimer() + b.StartTimer() for i := 0; i < b.N; i++ { h := sites[0]