fixed bucket tests

This commit is contained in:
Andrew Krasichkov 2019-02-14 15:54:01 +03:00
parent 3385784411
commit 8d8b062716

View file

@ -9,7 +9,7 @@ import (
type BucketTests struct {
}
func Tests_Bucket(t *testing.T) {
func Test_Bucket(t *testing.T) {
Expectify(new(BucketTests), t)
}
@ -42,10 +42,10 @@ func (_ *BucketTests) SetsANewBucketItem() {
func (_ *BucketTests) SetsAnExistingItem() {
bucket := testBucket()
item, existing := bucket.set("power", TestValue("9001"), time.Minute)
assertValue(item, "9002")
assertValue(item, "9001")
item = bucket.get("power")
assertValue(item, "9002")
assertValue(existing, "9001")
assertValue(item, "9001")
assertValue(existing, "9000")
}
func testBucket() *bucket {