aboutsummaryrefslogtreecommitdiff
path: root/bucket_test.go
diff options
context:
space:
mode:
authorBen Johnson <benbjohnson@yahoo.com>2014-03-13 17:14:21 -0700
committerBen Johnson <benbjohnson@yahoo.com>2014-03-13 17:14:21 -0700
commit60fd6f6604e598bf9ef2252f518a70ae6dcc4dda (patch)
tree244fe0bc3b2f17b27c7d806672087e54d3c0b5a1 /bucket_test.go
parentMerge pull request #64 from benbjohnson/fix-empty-cursor-last (diff)
parentSkip long-running tests with go test -short (diff)
downloaddedo-60fd6f6604e598bf9ef2252f518a70ae6dcc4dda.tar.gz
dedo-60fd6f6604e598bf9ef2252f518a70ae6dcc4dda.tar.xz
Merge pull request #66 from tv42/testing-short
Skip long-running tests with go test -short
Diffstat (limited to 'bucket_test.go')
-rw-r--r--bucket_test.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/bucket_test.go b/bucket_test.go
index 9ccc488..1970260 100644
--- a/bucket_test.go
+++ b/bucket_test.go
@@ -217,6 +217,10 @@ func TestBucketPutKeyTooLarge(t *testing.T) {
// Ensure a bucket can calculate stats.
func TestBucketStat(t *testing.T) {
+ if testing.Short() {
+ t.Skip("skipping test in short mode.")
+ }
+
withOpenDB(func(db *DB, path string) {
db.Do(func(tx *Tx) error {
// Add bucket with lots of keys.
@@ -273,6 +277,10 @@ func TestBucketStat(t *testing.T) {
// Ensure that a bucket can write random keys and values across multiple transactions.
func TestBucketPutSingle(t *testing.T) {
+ if testing.Short() {
+ t.Skip("skipping test in short mode.")
+ }
+
index := 0
f := func(items testdata) bool {
withOpenDB(func(db *DB, path string) {
@@ -313,6 +321,10 @@ func TestBucketPutSingle(t *testing.T) {
// Ensure that a transaction can insert multiple key/value pairs at once.
func TestBucketPutMultiple(t *testing.T) {
+ if testing.Short() {
+ t.Skip("skipping test in short mode.")
+ }
+
f := func(items testdata) bool {
withOpenDB(func(db *DB, path string) {
// Bulk insert all values.
@@ -347,6 +359,10 @@ func TestBucketPutMultiple(t *testing.T) {
// Ensure that a transaction can delete all key/value pairs and return to a single leaf page.
func TestBucketDeleteQuick(t *testing.T) {
+ if testing.Short() {
+ t.Skip("skipping test in short mode.")
+ }
+
f := func(items testdata) bool {
withOpenDB(func(db *DB, path string) {
// Bulk insert all values.