view .svn/pristine/61/61a91d37bba4f376ceeb50ad99e25e5c58c85000.svn-base @ 949:ebfda4c68b7a bug_505

Fixes Bug #505 (introduced in Bug #97): now also sends emails to all users members of a group when the group is added to a project.
author luisf <luis.figueira@eecs.qmul.ac.uk>
date Thu, 02 Aug 2012 19:40:23 +0100
parents cbb26bc654de
children
line wrap: on
line source
require File.dirname(__FILE__) + '/../test_helper'

class ExceptionNotificationCompatibilityTest < ActionController::TestCase
  ExceptionNotifier.exception_recipients = %w(joe@schmoe.com bill@schmoe.com)
  class SimpleController < ApplicationController
    include ExceptionNotifiable
    local_addresses.clear
    consider_all_requests_local = false
    def index
      begin
        raise "Fail!"
      rescue Exception => e
        rescue_action_in_public(e)
      end
    end
  end
  
  def setup
    @controller = SimpleController.new
    @request    = ActionController::TestRequest.new
    @response   = ActionController::TestResponse.new
  end
  
  def test_should_work
    assert_nothing_raised do
      get :index
    end
  end
end