aboutsummaryrefslogtreecommitdiff
path: root/cmd/bolt/get_test.go
diff options
context:
space:
mode:
authorBen Johnson <benbjohnson@yahoo.com>2014-04-15 23:45:06 -0400
committerBen Johnson <benbjohnson@yahoo.com>2014-04-15 23:45:06 -0400
commit2505b9a7dcca1e5d9d80ebfc6be7afcd97ba02dd (patch)
tree4d351709b0ec5d5eb1803b59c84e868c07889208 /cmd/bolt/get_test.go
parentFix race detector CI. (diff)
downloaddedo-2505b9a7dcca1e5d9d80ebfc6be7afcd97ba02dd.tar.gz
dedo-2505b9a7dcca1e5d9d80ebfc6be7afcd97ba02dd.tar.xz
Return bucket from CreateBucket() functions.
This commit changes the API for: Tx.CreateBucket() Tx.CreateBucketIfNotExists() Bucket.CreateBucket() Bucket.CreateBucketIfNotExists() These functions now return the *Bucket and error instead of just the error.
Diffstat (limited to 'cmd/bolt/get_test.go')
-rw-r--r--cmd/bolt/get_test.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/bolt/get_test.go b/cmd/bolt/get_test.go
index d491971..7b7c3a0 100644
--- a/cmd/bolt/get_test.go
+++ b/cmd/bolt/get_test.go
@@ -45,7 +45,8 @@ func TestGetKeyNotFound(t *testing.T) {
SetTestMode(true)
open(func(db *bolt.DB, path string) {
db.Update(func(tx *bolt.Tx) error {
- return tx.CreateBucket([]byte("widgets"))
+ _, err := tx.CreateBucket([]byte("widgets"))
+ return err
})
db.Close()
output := run("get", path, "widgets", "foo")