Skip to content

Instantly share code, notes, and snippets.

@mjgiarlo
Created January 24, 2017 22:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mjgiarlo/5ef6c83ba42572912cfdf53a3c7321ec to your computer and use it in GitHub Desktop.
Save mjgiarlo/5ef6c83ba42572912cfdf53a3c7321ec to your computer and use it in GitHub Desktop.
$ rspec spec/controllers/collections_controller_spec.rb:224
Run options: include {:locations=>{"./spec/controllers/collections_controller_spec.rb"=>[224]}}
Randomized with seed 3418
CollectionsController
#delete
when it succeeds
[20, 29] in /home/mjg/workspace/sufia/app/controllers/concerns/sufia/collections_controller_behavior.rb
20: redirect_to sufia.dashboard_collections_path,
21: notice: "Collection #{id} was successfully deleted"
22: end
23: wants.json do
24: byebug
=> 25: render json: { id: id, description: "Collection #{id} was successfully deleted" },
26: status: :success
27: end
28: end
29: end
(byebug) p response.code
"200"
(byebug) render json: { id: id, description: "Collection #{id} was successfully deleted" }, status: :success
"{\"id\":\"v979v304g\",\"description\":\"Collection v979v304g was successfully deleted\"}"
(byebug) p response.code
"500"
(byebug)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment