spec/dummy/app/controllers/api/v1/dummy_controller.rb in openstax_api-6.1.0 vs spec/dummy/app/controllers/api/v1/dummy_controller.rb in openstax_api-6.1.1

- old
+ new

@@ -1,11 +1,21 @@ module Api module V1 + class DummyControllerError < StandardError; end + class DummyController < OpenStax::Api::V1::ApiController + rescue_from DummyControllerError do |e| + render nothing: true, status: 500 + end + def dummy head(:ok) + end + + def explode + raise DummyControllerError, "kaboom" end end end