sort-cli: add benchmark

This commit is contained in:
2024-01-22 14:43:29 +03:00
parent 40182d4a46
commit 29fea2773f

View File

@ -55,3 +55,12 @@ func TestFlags(t *testing.T) {
})
}
}
func BenchmarkRun(b *testing.B) {
for i := 0; i < b.N; i++ {
flag.CommandLine = flag.NewFlagSet("Bench", flag.ExitOnError)
os.Args = append([]string{"Bench"}, "testdata/first")
_ = run()
}
}