commit | 3fa69b573f9ae2258a09f9556db351ed703ee5ee | [log] [tgz] |
---|---|---|
author | Oliver, Jonathan <git@jonathanoliver.com> | Fri May 30 15:07:54 2014 -0600 |
committer | Oliver, Jonathan <git@jonathanoliver.com> | Fri May 30 15:07:54 2014 -0600 |
tree | 57bb28b12450022ccd5134470a304628b0f41a37 | |
parent | d9c6b25840654b1a91390245835841a49fe56110 [diff] |
Cursor tests.
diff --git a/cursor_test.go b/cursor_test.go new file mode 100644 index 0000000..762996a --- /dev/null +++ b/cursor_test.go
@@ -0,0 +1,16 @@ +package disruptor + +import "testing" + +func BenchmarkWrites(b *testing.B) { + iterations := int64(b.N) + + cursor := NewCursor() + + b.ReportAllocs() + b.ResetTimer() + + for i := int64(0); i < iterations; i++ { + cursor.Store(i) + } +}