cirandas.net

ref: master

test/support/controller_test_case.rb


 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
class ActionController::TestCase

  class_attribute :default_params
  self.default_params = {}

  def get path, parameters = nil, session = nil, flash = nil
    super path, if parameters then self.default_params.merge parameters else self.default_params end, session, flash
  end

  def post path, parameters = nil, session = nil, flash = nil
    super path, if parameters then self.default_params.merge parameters else self.default_params end, session, flash
  end

end