mirror of
https://github.com/rclone/rclone.git
synced 2026-01-02 00:23:42 +00:00
vendor: update all dependencies
* Update all dependencies * Remove all `[[constraint]]` from Gopkg.toml * Add in the minimum number of `[[override]]` to build * Remove go get of github.com/inconshreveable/mousetrap as it is vendored * Update docs with new policy on constraints
This commit is contained in:
26
vendor/cloud.google.com/go/firestore/docref_test.go
generated
vendored
26
vendor/cloud.google.com/go/firestore/docref_test.go
generated
vendored
@@ -45,7 +45,15 @@ func TestDocGet(t *testing.T) {
|
||||
UpdateTime: aTimestamp,
|
||||
Fields: map[string]*pb.Value{"f": intval(1)},
|
||||
}
|
||||
srv.addRPC(&pb.GetDocumentRequest{Name: path}, pdoc)
|
||||
srv.addRPC(&pb.BatchGetDocumentsRequest{
|
||||
Database: c.path(),
|
||||
Documents: []string{path},
|
||||
}, []interface{}{
|
||||
&pb.BatchGetDocumentsResponse{
|
||||
Result: &pb.BatchGetDocumentsResponse_Found{pdoc},
|
||||
ReadTime: aTimestamp2,
|
||||
},
|
||||
})
|
||||
ref := c.Collection("C").Doc("a")
|
||||
gotDoc, err := ref.Get(ctx)
|
||||
if err != nil {
|
||||
@@ -55,6 +63,7 @@ func TestDocGet(t *testing.T) {
|
||||
Ref: ref,
|
||||
CreateTime: aTime,
|
||||
UpdateTime: aTime,
|
||||
ReadTime: aTime2,
|
||||
proto: pdoc,
|
||||
c: c,
|
||||
}
|
||||
@@ -62,12 +71,17 @@ func TestDocGet(t *testing.T) {
|
||||
t.Fatalf("\ngot %+v\nwant %+v", gotDoc, wantDoc)
|
||||
}
|
||||
|
||||
path2 := "projects/projectID/databases/(default)/documents/C/b"
|
||||
srv.addRPC(
|
||||
&pb.GetDocumentRequest{
|
||||
Name: "projects/projectID/databases/(default)/documents/C/b",
|
||||
},
|
||||
grpc.Errorf(codes.NotFound, "not found"),
|
||||
)
|
||||
&pb.BatchGetDocumentsRequest{
|
||||
Database: c.path(),
|
||||
Documents: []string{path2},
|
||||
}, []interface{}{
|
||||
&pb.BatchGetDocumentsResponse{
|
||||
Result: &pb.BatchGetDocumentsResponse_Missing{path2},
|
||||
ReadTime: aTimestamp3,
|
||||
},
|
||||
})
|
||||
_, err = c.Collection("C").Doc("b").Get(ctx)
|
||||
if grpc.Code(err) != codes.NotFound {
|
||||
t.Errorf("got %v, want NotFound", err)
|
||||
|
||||
Reference in New Issue
Block a user