Skip to content

Commit c23285b

Browse files
committed
benchmark
1 parent f686c05 commit c23285b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

defaults_test.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,3 +88,10 @@ func (self *DefaultsSuite) TestSetDefaultsWithValues(c *C) {
8888
c.Assert(foo.String, Equals, "bar")
8989
c.Assert(string(foo.Bytes), Equals, "foo")
9090
}
91+
92+
func (self *DefaultsSuite) BenchmarkLogic(c *C) {
93+
for i := 0; i < c.N; i++ {
94+
foo := &ExampleBasic{}
95+
SetDefaults(foo)
96+
}
97+
}

0 commit comments

Comments
 (0)