[ARVADOS] updated: 1.2.0-110-g395e42cc2
Git user
git at public.curoverse.com
Thu Sep 27 17:24:24 EDT 2018
Summary of changes:
lib/controller/federation_test.go | 23 ++++++++++++++++++-----
1 file changed, 18 insertions(+), 5 deletions(-)
via 395e42cc2eb11b52ab5e36b29421edcdea3a3dbf (commit)
from ce572d4c9234b6e08940f2ce265578a1e99b83f4 (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 395e42cc2eb11b52ab5e36b29421edcdea3a3dbf
Author: Peter Amstutz <pamstutz at veritasgenetics.com>
Date: Thu Sep 27 17:23:45 2018 -0400
13619: Test that "select" is passed through multi-object query
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <pamstutz at veritasgenetics.com>
diff --git a/lib/controller/federation_test.go b/lib/controller/federation_test.go
index f165aecff..6a44c7cbd 100644
--- a/lib/controller/federation_test.go
+++ b/lib/controller/federation_test.go
@@ -610,21 +610,34 @@ func (s *FederationSuite) TestListRemoteContainer(c *check.C) {
func (s *FederationSuite) TestListMultiRemoteContainers(c *check.C) {
defer s.localServiceHandler(c, http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) {
bd, _ := ioutil.ReadAll(req.Body)
- c.Check(string(bd), check.Equals, `_method=GET&count=none&filters=%5B%5B%22uuid%22%2C+%22in%22%2C+%5B%22zhome-xvhdp-cr5queuedcontnr%22%5D%5D%5D`)
+ c.Check(string(bd), check.Equals, `_method=GET&count=none&filters=%5B%5B%22uuid%22%2C+%22in%22%2C+%5B%22zhome-xvhdp-cr5queuedcontnr%22%5D%5D%5D&select=%5B%22uuid%22%2C+%22command%22%5D`)
w.WriteHeader(200)
- w.Write([]byte(`{"kind": "arvados#containerList", "items": [{"uuid": "zhome-xvhdp-cr5queuedcontnr"}]}`))
+ w.Write([]byte(`{"kind": "arvados#containerList", "items": [{"uuid": "zhome-xvhdp-cr5queuedcontnr", "command": ["abc"]}]}`))
})).Close()
- req := httptest.NewRequest("GET", "/arvados/v1/containers?count=none&filters="+
- url.QueryEscape(fmt.Sprintf(`[["uuid", "in", ["%v", "zhome-xvhdp-cr5queuedcontnr"]]]`, arvadostest.QueuedContainerUUID)), nil)
+ req := httptest.NewRequest("GET", fmt.Sprintf("/arvados/v1/containers?count=none&filters=%s&select=%s",
+ url.QueryEscape(fmt.Sprintf(`[["uuid", "in", ["%v", "zhome-xvhdp-cr5queuedcontnr"]]]`,
+ arvadostest.QueuedContainerUUID)),
+ url.QueryEscape(`["uuid", "command"]`)),
+ nil)
req.Header.Set("Authorization", "Bearer "+arvadostest.ActiveToken)
resp := s.testRequest(req)
c.Check(resp.StatusCode, check.Equals, http.StatusOK)
var cn arvados.ContainerList
c.Check(json.NewDecoder(resp.Body).Decode(&cn), check.IsNil)
if cn.Items[0].UUID == arvadostest.QueuedContainerUUID {
+ c.Check(cn.Items[0].Command, check.DeepEquals, []string{"echo", "hello"})
+ c.Check(cn.Items[0].ContainerImage, check.Equals, "")
+
c.Check(cn.Items[1].UUID, check.Equals, "zhome-xvhdp-cr5queuedcontnr")
+ c.Check(cn.Items[1].Command, check.DeepEquals, []string{"abc"})
+ c.Check(cn.Items[1].ContainerImage, check.Equals, "")
} else {
- c.Check(cn.Items[1].UUID, check.Equals, arvadostest.QueuedContainerUUID)
c.Check(cn.Items[0].UUID, check.Equals, "zhome-xvhdp-cr5queuedcontnr")
+ c.Check(cn.Items[0].Command, check.DeepEquals, []string{"abc"})
+ c.Check(cn.Items[0].ContainerImage, check.Equals, "")
+
+ c.Check(cn.Items[1].UUID, check.Equals, arvadostest.QueuedContainerUUID)
+ c.Check(cn.Items[1].Command, check.DeepEquals, []string{"echo", "hello"})
+ c.Check(cn.Items[1].ContainerImage, check.Equals, "")
}
}
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list