Bug #29245
closedmodulemd endpoint now correctly returns arrays instead of strings
Description
Before:
[2] pry(main)> service = Katello::Pulp3::ModuleStream.new("/pulp/api/v3/content/rpm/modulemds/81b526ae-0a09-43bf-9ab1-9402955a09f6/")
=> #<Katello::Pulp3::ModuleStream:0x0000000011e43368 @uuid="/pulp/api/v3/content/rpm/modulemds/81b526ae-0a09-43bf-9ab1-9402955a09f6/">
[3] pry(main)> service.backend_data['artifacts']
=> "[\"walrus-0:0.71-1.noarch\"]"
[4] pry(main)> JSON.parse service.backend_data['artifacts']
=> ["walrus-0:0.71-1.noarch"]
On pulpcore master:
[8] pry(main)> service.backend_data['artifacts']
=> ["duck-0:0.6-1.noarch"]
[9] pry(main)> JSON.parse service.backend_data['artifacts']
TypeError: no implicit conversion of Array into String
from /home/vagrant/foreman/.vendor/ruby/2.5.0/gems/json-2.3.0/lib/json/common.rb:156:in `initialize'