commit
ec06cd93a0
1 changed files with 4 additions and 4 deletions
|
@ -9,7 +9,7 @@ import (
|
||||||
type BucketTests struct {
|
type BucketTests struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
func Tests_Bucket(t *testing.T) {
|
func Test_Bucket(t *testing.T) {
|
||||||
Expectify(new(BucketTests), t)
|
Expectify(new(BucketTests), t)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -42,10 +42,10 @@ func (_ *BucketTests) SetsANewBucketItem() {
|
||||||
func (_ *BucketTests) SetsAnExistingItem() {
|
func (_ *BucketTests) SetsAnExistingItem() {
|
||||||
bucket := testBucket()
|
bucket := testBucket()
|
||||||
item, existing := bucket.set("power", TestValue("9001"), time.Minute)
|
item, existing := bucket.set("power", TestValue("9001"), time.Minute)
|
||||||
assertValue(item, "9002")
|
assertValue(item, "9001")
|
||||||
item = bucket.get("power")
|
item = bucket.get("power")
|
||||||
assertValue(item, "9002")
|
assertValue(item, "9001")
|
||||||
assertValue(existing, "9001")
|
assertValue(existing, "9000")
|
||||||
}
|
}
|
||||||
|
|
||||||
func testBucket() *bucket {
|
func testBucket() *bucket {
|
||||||
|
|
Loading…
Reference in a new issue