[ARVADOS] updated: d3c7b9502d9297d71225ebdbb81616f7613348b5
git at public.curoverse.com
git at public.curoverse.com
Fri Oct 9 14:34:20 EDT 2015
Summary of changes:
sdk/go/keepclient/keepclient_test.go | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
via d3c7b9502d9297d71225ebdbb81616f7613348b5 (commit)
from 8653e6d34f5d895ee56fe3657c7fc3ca3cf615f4 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit d3c7b9502d9297d71225ebdbb81616f7613348b5
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date: Fri Oct 9 14:36:15 2015 -0400
7491: Add test that default replication is read from discovery document.
diff --git a/sdk/go/keepclient/keepclient_test.go b/sdk/go/keepclient/keepclient_test.go
index e2c4d90..95269bf 100644
--- a/sdk/go/keepclient/keepclient_test.go
+++ b/sdk/go/keepclient/keepclient_test.go
@@ -69,6 +69,22 @@ func (s *ServerRequiredSuite) TestMakeKeepClient(c *C) {
}
}
+func (s *ServerRequiredSuite) TestDefaultReplications(c *C) {
+ arv, err := arvadosclient.MakeArvadosClient()
+ c.Assert(err, Equals, nil)
+
+ kc, err := MakeKeepClient(&arv)
+ c.Assert(kc.Want_replicas, Equals, 2)
+
+ arv.DiscoveryDoc["defaultCollectionReplication"] = 3.0
+ kc, err = MakeKeepClient(&arv)
+ c.Assert(kc.Want_replicas, Equals, 3)
+
+ arv.DiscoveryDoc["defaultCollectionReplication"] = 1.0
+ kc, err = MakeKeepClient(&arv)
+ c.Assert(kc.Want_replicas, Equals, 1)
+}
+
type StubPutHandler struct {
c *C
expectPath string
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list