Output JSON from rails pets:load[pet_name]
Gonna use this for making mock data for automatic testing!
This commit is contained in:
parent
09e5a39b4c
commit
881e63cfbd
1 changed files with 2 additions and 1 deletions
|
@ -1,7 +1,8 @@
|
|||
namespace :pets do
|
||||
desc "Load a pet's viewer data"
|
||||
task :load, [:name] => [:environment] do |task, args|
|
||||
pp Neopets::CustomPets.fetch_viewer_data(args[:name])
|
||||
viewer_data = Neopets::CustomPets.fetch_viewer_data(args[:name])
|
||||
puts JSON.pretty_generate(viewer_data)
|
||||
end
|
||||
|
||||
desc "Find pets that were, last we saw, of the given color and species"
|
||||
|
|
Loading…
Reference in a new issue