This moves the error variables that had been moved to the
internal/common package during recent refactoring to a non-internal
errors package, once again allowing consumers to test for particular
error conditions.
To preserve API compatibility with bbolt v1.3, these error variables
are also redefined in the bbolt package, with deprecation notice to
migrate to bbolt/errors.
Signed-off-by: Josh Rickmar <jrick@zettaport.com>
This commit refactors the test suite to make it cleaner and to use the
standard testing library better. The `assert()`, `equals()`, and `ok()`
functions have been removed and some test names have been changed for
clarity.
No functionality has been changed.
This commit fixes an issue where keys are skipped by cursors after
deletions occur in a bucket. This occurred because the cursor seeks
to the leaf page but does not check if it is empty.
Fixes#429, #450
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.