X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/1a0a58c4f22af82e0a37440af3b0948771bca5e1..a942e37250873d383bd885ba0dba70c63b3c073d:/services/api/test/functional/arvados/v1/groups_controller_test.rb diff --git a/services/api/test/functional/arvados/v1/groups_controller_test.rb b/services/api/test/functional/arvados/v1/groups_controller_test.rb index e8ce6fd6df..de339c9554 100644 --- a/services/api/test/functional/arvados/v1/groups_controller_test.rb +++ b/services/api/test/functional/arvados/v1/groups_controller_test.rb @@ -31,11 +31,11 @@ class Arvados::V1::GroupsControllerTest < ActionController::TestCase test "get list of groups that are not projects" do authorize_with :active - get :index, filters: [['group_class', '=', nil]], format: :json + get :index, filters: [['group_class', '!=', 'project']], format: :json assert_response :success group_uuids = [] json_response['items'].each do |group| - assert_equal nil, group['group_class'] + assert_not_equal 'project', group['group_class'] group_uuids << group['uuid'] end assert_not_includes group_uuids, groups(:aproject).uuid @@ -239,19 +239,6 @@ class Arvados::V1::GroupsControllerTest < ActionController::TestCase assert_equal 0, json_response['items_available'] end - test 'get group-owned objects without include_linked' do - unexpected_uuid = specimens(:in_aproject_linked_from_asubproject).uuid - authorize_with :active - get :contents, { - id: groups(:asubproject).uuid, - format: :json, - } - assert_response :success - uuids = json_response['items'].collect { |i| i['uuid'] } - assert_equal nil, uuids.index(unexpected_uuid) - end - - test "get all pages of group-owned objects" do authorize_with :active limit = 5 @@ -324,8 +311,9 @@ class Arvados::V1::GroupsControllerTest < ActionController::TestCase format: :json } assert_response :success - assert_nil(json_response['writable_by'], - "Should not receive uuid list in 'writable_by' field") + assert_equal([json_response['owner_uuid']], + json_response['writable_by'], + "Should only see owner_uuid in 'writable_by' field") end test 'get writable_by list by admin user' do