expired_col = collections(:expired_collection)
assert expired_col.is_trashed
# Try #index first
- get "/arvados/v1/collections",
+ post "/arvados/v1/collections",
params: {
+ :_method => 'GET',
:include_trash => param,
:filters => [['uuid', '=', expired_col.uuid]].to_json
},
assert_not_nil json_response['items']
assert_equal truthiness, json_response['items'].collect {|c| c['uuid']}.include?(expired_col.uuid)
# Try #show next
- get "/arvados/v1/collections/#{expired_col.uuid}",
+ post "/arvados/v1/collections/#{expired_col.uuid}",
params: {
- :format => :json,
+ :_method => 'GET',
:include_trash => param,
},
headers: auth(:active)
expired_col = collections(:expired_collection)
assert expired_col.is_trashed
params = [
+ ['_method', 'GET'],
['include_trash', param],
['filters', [['uuid','=',expired_col.uuid]].to_json],
]
# Try #index first
- get "/arvados/v1/collections",
+ post "/arvados/v1/collections",
params: URI.encode_www_form(params),
headers: {
"Content-type" => "application/x-www-form-urlencoded"
assert_not_nil json_response['items']
assert_equal truthiness, json_response['items'].collect {|c| c['uuid']}.include?(expired_col.uuid)
# Try #show next
- get "/arvados/v1/collections/#{expired_col.uuid}",
- params: URI.encode_www_form([['include_trash', param]]),
+ post "/arvados/v1/collections/#{expired_col.uuid}",
+ params: URI.encode_www_form([['_method', 'GET'],['include_trash', param]]),
headers: {
"Content-type" => "application/x-www-form-urlencoded"
}.update(auth(:active))