1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actionpack/test/template/body_parts_test.rb

27 lines
623 B
Ruby
Raw Normal View History

require 'abstract_unit'
2009-03-16 15:09:34 -04:00
class BodyPartsTest < ActionController::TestCase
RENDERINGS = [Object.new, Object.new, Object.new]
class TestController < ActionController::Base
def index
2009-03-13 21:49:53 -04:00
RENDERINGS.each do |rendering|
@template.punctuate_body! rendering
2009-03-13 21:49:53 -04:00
end
@performed_render = true
end
end
tests TestController
2009-03-16 15:09:34 -04:00
def test_body_parts
get :index
pending do
# TestProcess buffers body_parts into body
# TODO: Rewrite test w/o going through process
assert_equal RENDERINGS, @response.body_parts
end
2009-03-16 15:09:34 -04:00
assert_equal RENDERINGS.join, @response.body
end
end