X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/675794872a5d064cf0a8177d662555c04b0dae51..5054334a7417e35990e020aecf852a5eb3056108:/services/api/test/functional/arvados/v1/keep_services_controller_test.rb diff --git a/services/api/test/functional/arvados/v1/keep_services_controller_test.rb b/services/api/test/functional/arvados/v1/keep_services_controller_test.rb index bfa138d72c..1375d4c9ce 100644 --- a/services/api/test/functional/arvados/v1/keep_services_controller_test.rb +++ b/services/api/test/functional/arvados/v1/keep_services_controller_test.rb @@ -2,7 +2,7 @@ require 'test_helper' class Arvados::V1::KeepServicesControllerTest < ActionController::TestCase - test "search keep_services by service_port with < query" do + test "search by service_port with < query" do authorize_with :active get :index, { filters: [['service_port', '<', 25107]] @@ -11,7 +11,7 @@ class Arvados::V1::KeepServicesControllerTest < ActionController::TestCase assert_equal false, assigns(:objects).any? end - test "search keep_disks by service_port with >= query" do + test "search by service_port with >= query" do authorize_with :active get :index, { filters: [['service_port', '>=', 25107]] @@ -20,4 +20,16 @@ class Arvados::V1::KeepServicesControllerTest < ActionController::TestCase assert_equal true, assigns(:objects).any? end + [:admin, :active, :inactive, :anonymous].each do |u| + test "accessible to #{u} user" do + authorize_with u + get :accessible + assert_response :success + assert_not_empty json_response['items'] + json_response['items'].each do |ks| + assert_not_equal ks['service_type'], 'proxy' + end + end + end + end