- test "add keep disk with no filesystem_uuid" do
- authorize_with :admin
- opts = {
- ping_secret: '',
- }
- post :ping, opts
- assert_response :success
- assert_not_nil JSON.parse(@response.body)['uuid']
-
- post :ping, opts.merge(filesystem_uuid: '')
- assert_response :success
- assert_not_nil JSON.parse(@response.body)['uuid']
+ [
+ {},
+ {filesystem_uuid: ''},
+ ].each do |opts|
+ test "add keep disk with[out] filesystem_uuid #{opts}" do
+ authorize_with :admin
+ post :ping, default_ping_opts.merge(opts)
+ assert_response :success
+ assert_not_nil JSON.parse(@response.body)['uuid']
+ end