Moving all the functional tests to the Rails 2 way, which uses less code by having an additional sub-class to take care of the duplicate code in every test. There is a bug in rails 2.0.2, which means that super doesn't get called in the setup method in the functional tests. This is fixed in Rails 2.1.2, thus a version bump should really be done.
This commit is contained in:
parent
e18c33f733
commit
427becc1db
12 changed files with 13 additions and 111 deletions
|
@ -1,18 +1,9 @@
|
|||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
require 'old_way_controller'
|
||||
|
||||
# Re-raise errors caught by the controller.
|
||||
class OldWayController; def rescue_action(e) raise e end; end
|
||||
|
||||
class OldWayControllerTest < Test::Unit::TestCase
|
||||
class OldWayControllerTest < ActionController::TestCase
|
||||
api_fixtures
|
||||
|
||||
def setup
|
||||
@controller = OldWayController.new
|
||||
@request = ActionController::TestRequest.new
|
||||
@response = ActionController::TestResponse.new
|
||||
end
|
||||
|
||||
# -------------------------------------
|
||||
# Test reading old ways.
|
||||
# -------------------------------------
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue