[arvados] updated: 2.1.0-2789-g3e95703e7
git repository hosting
git at public.arvados.org
Thu Jul 28 14:12:52 UTC 2022
Summary of changes:
.../api/app/controllers/arvados/v1/groups_controller.rb | 2 +-
services/api/test/functional/arvados/v1/filters_test.rb | 14 ++++++++++++--
2 files changed, 13 insertions(+), 3 deletions(-)
via 3e95703e7444c1d2077eba748740ebe3df94b1d5 (commit)
from 6cd62b6e286d4470ef9e2b2c70653d78a05f8cf2 (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 3e95703e7444c1d2077eba748740ebe3df94b1d5
Author: Lucas Di Pentima <lucas.dipentima at curii.com>
Date: Thu Jul 28 11:11:47 2022 -0300
19297: Fixes error check for edge case of limit=0, count=none. Adds test.
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <lucas.dipentima at curii.com>
diff --git a/services/api/app/controllers/arvados/v1/groups_controller.rb b/services/api/app/controllers/arvados/v1/groups_controller.rb
index de0c43a77..e9bc006a3 100644
--- a/services/api/app/controllers/arvados/v1/groups_controller.rb
+++ b/services/api/app/controllers/arvados/v1/groups_controller.rb
@@ -365,7 +365,7 @@ class Arvados::V1::GroupsController < ApplicationController
end
# Only error out when every searchable object type errored out
- if !any_success
+ if !any_success && error_by_class.size > 0
error_msg = error_by_class.collect do |klass, err|
"#{err} on object type #{klass}"
end.join("\n")
diff --git a/services/api/test/functional/arvados/v1/filters_test.rb b/services/api/test/functional/arvados/v1/filters_test.rb
index 7eac47771..3916d63c5 100644
--- a/services/api/test/functional/arvados/v1/filters_test.rb
+++ b/services/api/test/functional/arvados/v1/filters_test.rb
@@ -271,13 +271,23 @@ class Arvados::V1::FiltersTest < ActionController::TestCase
filters: [
['properties', 'exists', 'foo'],
['uuid', 'is_a', ["arvados#workflow"]],
- ],
- limit: 1
+ ]
}
assert_response 422
assert_match(/Invalid attribute 'properties' for operator 'exists'.*on object type Workflow/, json_response['errors'].join(' '))
end
+ test "groups contents without filters and limit=0, count=none" do
+ @controller = Arvados::V1::GroupsController.new
+ authorize_with :admin
+ get :contents, params: {
+ limit: 0,
+ count: 'none',
+ }
+ assert_response 200
+ assert json_response['items'].length == 0
+ end
+
test "replication_desired = 2" do
@controller = Arvados::V1::CollectionsController.new
authorize_with :admin
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list