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

Unified Diff: impl/dummy/dummy_test.go

Issue 1253263002: Make rawdatastore API safer for writing filters. (Closed) Base URL: https://github.com/luci/gae.git@master
Patch Set: fix comments Created 5 years, 5 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/dummy/dummy.go ('k') | impl/memory/globalinfo.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: impl/dummy/dummy_test.go
diff --git a/impl/dummy/dummy_test.go b/impl/dummy/dummy_test.go
index dcb9eb65de0fd0e27d8b29885a35afadf4017686..ed27c493cc764366704751789bda33235fe5b69d 100644
--- a/impl/dummy/dummy_test.go
+++ b/impl/dummy/dummy_test.go
@@ -33,13 +33,24 @@ func TestContextAccess(t *testing.T) {
So(infoS.Get(c), ShouldBeNil)
})
+ // needed for everything else
+ c = infoS.Set(c, Info())
+
+ Convey("Info", func() {
+ So(infoS.Get(c), ShouldNotBeNil)
+ So(func() {
+ defer p()
+ infoS.Get(c).Datacenter()
+ }, ShouldPanicWith, "dummy: method Info.Datacenter is not implemented")
+ })
+
Convey("RawDatastore", func() {
c = rdsS.Set(c, RawDatastore())
So(rdsS.Get(c), ShouldNotBeNil)
So(func() {
defer p()
- rdsS.Get(c).NewKey("", "", 1, nil)
- }, ShouldPanicWith, "dummy: method RawDatastore.NewKey is not implemented")
+ rdsS.Get(c).DecodeKey("wut")
+ }, ShouldPanicWith, "dummy: method RawDatastore.DecodeKey is not implemented")
})
Convey("Memcache", func() {
@@ -60,13 +71,5 @@ func TestContextAccess(t *testing.T) {
}, ShouldPanicWith, "dummy: method TaskQueue.Purge is not implemented")
})
- Convey("Info", func() {
- c = infoS.Set(c, Info())
- So(infoS.Get(c), ShouldNotBeNil)
- So(func() {
- defer p()
- infoS.Get(c).Datacenter()
- }, ShouldPanicWith, "dummy: method Info.Datacenter is not implemented")
- })
})
}
« no previous file with comments | « impl/dummy/dummy.go ('k') | impl/memory/globalinfo.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698