Skip to content

Commit 0f61114

Browse files
committed
fixup: add group example
1 parent ec5ef86 commit 0f61114

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

example/fib_test.go

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,13 @@ func BenchmarkFibonacci20(b *testing.B) {
2121
}
2222

2323
func BenchmarkFibonacci30(b *testing.B) {
24-
for i := 0; i < b.N; i++ {
25-
fibonacci(30)
26-
}
24+
b.Run("fibonacci(30)", func(b *testing.B) {
25+
b.Run("fibonacci(30)", func(b *testing.B) {
26+
b.Run("fibonacci(30)", func(b *testing.B) {
27+
for i := 0; i < b.N; i++ {
28+
fibonacci(30)
29+
}
30+
})
31+
})
32+
})
2733
}

0 commit comments

Comments
 (0)