diff options
author | Ben Johnson <benbjohnson@yahoo.com> | 2014-04-16 11:30:03 -0400 |
---|---|---|
committer | Ben Johnson <benbjohnson@yahoo.com> | 2014-04-16 11:30:03 -0400 |
commit | a8cb83c00826f8acbad841e30cbdeba75eaae21f (patch) | |
tree | 187970f941e736da74dea40477f72589266a85c0 /c/cursor_test.go | |
parent | wip (diff) | |
download | dedo-a8cb83c00826f8acbad841e30cbdeba75eaae21f.tar.gz dedo-a8cb83c00826f8acbad841e30cbdeba75eaae21f.tar.xz |
Fix pointer arithematic.
Diffstat (limited to 'c/cursor_test.go')
-rw-r--r-- | c/cursor_test.go | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/c/cursor_test.go b/c/cursor_test.go index f938881..3ac621f 100644 --- a/c/cursor_test.go +++ b/c/cursor_test.go @@ -1,7 +1,6 @@ package c import ( - "fmt" "io/ioutil" "os" // "sort" @@ -62,7 +61,7 @@ func TestCursorFirst(t *testing.T) { // Bulk insert all values. tx, _ := db.Begin(true) b, _ := tx.CreateBucket([]byte("widgets")) - assert.NoError(t, b.Put([]byte("foo"), []byte("bar"))) + assert.NoError(t, b.Put([]byte("foo"), []byte("barz"))) assert.NoError(t, tx.Commit()) // Get first and check consistency @@ -70,7 +69,7 @@ func TestCursorFirst(t *testing.T) { c := NewCursor(tx.Bucket([]byte("widgets"))) key, value := first(c) assert.Equal(t, key, []byte("foo")) - assert.Equal(t, value, []byte("bar")) + assert.Equal(t, value, []byte("barz")) tx.Rollback() }) @@ -122,11 +121,3 @@ func mustCheck(db *bolt.DB) { panic("check failure: see /tmp/check.db") } } - -func warn(v ...interface{}) { - fmt.Fprintln(os.Stderr, v...) -} - -func warnf(msg string, v ...interface{}) { - fmt.Fprintf(os.Stderr, msg+"\n", v...) -} |