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

Unified Diff: filter/txnBuf/txnbuf_test.go

Issue 2007123002: datastore: Update AllocateIDs to take keys. (Closed) Base URL: https://chromium.googlesource.com/external/github.com/luci/gae@master
Patch Set: Add empty arg/key short-circuits for other varidic methods. Created 4 years, 7 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
Index: filter/txnBuf/txnbuf_test.go
diff --git a/filter/txnBuf/txnbuf_test.go b/filter/txnBuf/txnbuf_test.go
index aabdc5ed839bbfd29a2361eb9de507968b20eb52..7c0565940513b3f5b554e4616757c74e76b9a306 100644
--- a/filter/txnBuf/txnbuf_test.go
+++ b/filter/txnBuf/txnbuf_test.go
@@ -130,8 +130,9 @@ func init() {
func mkds(data []*Foo) (under, over *count.DSCounter, ds datastore.Interface) {
c := memory.UseWithAppID(context.Background(), "something~else")
ds = datastore.Get(c)
- _, err := ds.AllocateIDs(ds.KeyForObj(data[0]), 100)
- if err != nil {
+
+ dataKey := ds.KeyForObj(data[0])
+ if err := ds.AllocateIDs(ds.NewIncompleteKeys(100, dataKey.Kind(), dataKey.Parent())); err != nil {
panic(err)
}
if err := ds.PutMulti(data); err != nil {
« no previous file with comments | « filter/txnBuf/state.go ('k') | impl/dummy/dummy.go » ('j') | impl/memory/datastore_data.go » ('J')

Powered by Google App Engine
This is Rietveld 408576698