Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Unified Diff: impl/memory/memcache_test.go

Issue 1355783002: Refactor keys and queries in datastore service and implementation. (Closed) Base URL: https://github.com/luci/gae.git@master
Patch Set: appease errcheck Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « impl/memory/memcache.go ('k') | impl/memory/taskqueue_test.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: impl/memory/memcache_test.go
diff --git a/impl/memory/memcache_test.go b/impl/memory/memcache_test.go
index aa0c17d8c776b73a111f0b0e34c0eb4f91f34132..73fa2b46da2f56444bfbbc452c9ba1eee7663a1e 100644
--- a/impl/memory/memcache_test.go
+++ b/impl/memory/memcache_test.go
@@ -10,6 +10,7 @@ import (
mcS "github.com/luci/gae/service/memcache"
"github.com/luci/luci-go/common/clock/testclock"
+ . "github.com/luci/luci-go/common/testing/assertions"
. "github.com/smartystreets/goconvey/convey"
"golang.org/x/net/context"
)
@@ -101,7 +102,7 @@ func TestMemcache(t *testing.T) {
So(getItm, ShouldResemble, testItem)
Convey("Flush works too", func() {
- mc.Flush()
+ So(mc.Flush(), ShouldBeNil)
So(mc.Get(getItm), ShouldEqual, mcS.ErrCacheMiss)
})
})
@@ -168,11 +169,11 @@ func TestMemcache(t *testing.T) {
expiration: time.Second * 2,
})
- mc.Get(mc.NewItem("sup"))
- mc.Get(mc.NewItem("sup"))
- mc.Get(mc.NewItem("sup"))
- mc.Get(mc.NewItem("sup"))
- mc.Get(mc.NewItem("wot"))
+ So(mc.Get(mc.NewItem("sup")), ShouldBeNil)
+ So(mc.Get(mc.NewItem("sup")), ShouldBeNil)
+ So(mc.Get(mc.NewItem("sup")), ShouldBeNil)
+ So(mc.Get(mc.NewItem("sup")), ShouldBeNil)
+ So(mc.Get(mc.NewItem("wot")), ShouldErrLike, mcS.ErrCacheMiss)
mci := mc.Raw().(*memcacheImpl)
« no previous file with comments | « impl/memory/memcache.go ('k') | impl/memory/taskqueue_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698