forked from rosa/hakurei
internal/rosa: drop caches
This enables accurate benchmarking of the toolchain abstraction. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -19,6 +19,18 @@ func TestLoad(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func BenchmarkAll(b *testing.B) {
|
||||
for b.Loop() {
|
||||
for i := range rosa.PresetEnd {
|
||||
rosa.Std.Load(rosa.PArtifact(i))
|
||||
}
|
||||
|
||||
b.StopTimer()
|
||||
rosa.DropCaches()
|
||||
b.StartTimer()
|
||||
}
|
||||
}
|
||||
|
||||
func TestResolveName(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user