From e1056530665d5c8eed2c325157fbb88553eb2678 Mon Sep 17 00:00:00 2001
From: David Heinemeier Hansson <%= link_to(post.title, :action => "display", :id => post.id %>
<%= post.title %> No people in the address book yet <%= @topic.body %> Good seeing you! Parameters:
<%= post.content %>
Address Book
-
-<% if @people.empty? %>
-
-
-<% end %>
-
-
\ No newline at end of file
diff --git a/actionpack/examples/address_book/layout.rhtml b/actionpack/examples/address_book/layout.rhtml
index 931e141c01..e69de29bb2 100644
--- a/actionpack/examples/address_book/layout.rhtml
+++ b/actionpack/examples/address_book/layout.rhtml
@@ -1,8 +0,0 @@
-
-
-
- <% for person in @people %>
- Name Email Address Phone Number
- <% end %>
- <%= person.name %> <%= person.email_address %> <%= person.phone_number %> Topics
-
-<%= link_to "New topic", :action => "new_topic" %>
-
-
-<% for topic in @topics %>
-
-
-
-
\ No newline at end of file
diff --git a/actionpack/examples/debate/new_topic.rhtml b/actionpack/examples/debate/new_topic.rhtml
index f52a69cc31..e69de29bb2 100644
--- a/actionpack/examples/debate/new_topic.rhtml
+++ b/actionpack/examples/debate/new_topic.rhtml
@@ -1,22 +0,0 @@
-
-
-New topic
-
-
-
-
-
\ No newline at end of file
diff --git a/actionpack/examples/debate/topic.rhtml b/actionpack/examples/debate/topic.rhtml
index e247c00f0d..e69de29bb2 100644
--- a/actionpack/examples/debate/topic.rhtml
+++ b/actionpack/examples/debate/topic.rhtml
@@ -1,32 +0,0 @@
-
-
-<%= @topic.title %>
-
-Replies
-
- <% for reply in @topic.replies %>
-
-<% end %>
-
-Reply to this topic
-
-
-
-
-
\ No newline at end of file
diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb
index 360e115f16..39ffb06212 100755
--- a/actionpack/lib/action_controller/base.rb
+++ b/actionpack/lib/action_controller/base.rb
@@ -71,7 +71,7 @@ module ActionController #:nodoc:
#
# Actions, by default, render a template in the app/views directory corresponding to the name of the controller and action
# after executing code in the action. For example, the +index+ action of the +GuestBookController+ would render the
- # template app/views/guestbook/index.rhtml by default after populating the @entries instance variable.
+ # template app/views/guestbook/index.erb by default after populating the @entries instance variable.
#
# Unlike index, the sign action will not render a template. After performing its main purpose (creating a
# new entry in the guest book), it initiates a redirect instead. This redirect works by returning an external
@@ -662,7 +662,7 @@ module ActionController #:nodoc:
# Template rendering works just like action rendering except that it takes a path relative to the template root.
# The current layout is automatically applied.
#
- # # Renders the template located in [TEMPLATE_ROOT]/weblog/show.r(html|xml) (in Rails, app/views/weblog/show.rhtml)
+ # # Renders the template located in [TEMPLATE_ROOT]/weblog/show.r(html|xml) (in Rails, app/views/weblog/show.erb)
# render :template => "weblog/show"
#
# === Rendering a file
@@ -671,12 +671,12 @@ module ActionController #:nodoc:
# is assumed to be absolute, and the current layout is not applied.
#
# # Renders the template located at the absolute filesystem path
- # render :file => "/path/to/some/template.rhtml"
- # render :file => "c:/path/to/some/template.rhtml"
+ # render :file => "/path/to/some/template.erb"
+ # render :file => "c:/path/to/some/template.erb"
#
# # Renders a template within the current layout, and with a 404 status code
- # render :file => "/path/to/some/template.rhtml", :layout => true, :status => 404
- # render :file => "c:/path/to/some/template.rhtml", :layout => true, :status => 404
+ # render :file => "/path/to/some/template.erb", :layout => true, :status => 404
+ # render :file => "c:/path/to/some/template.erb", :layout => true, :status => 404
#
# # Renders a template relative to the template root and chooses the proper file extension
# render :file => "some/template", :use_full_path => true
@@ -734,7 +734,7 @@ module ActionController #:nodoc:
# render :inline => "<%= 'hello, ' * 3 + 'again' %>"
#
# # Renders ">
-<% end %>
-
-<% if false %>
- <%=h @exception.describe_blame %>
- <% begin %>
- <%= form_tag(request.request_uri, "method" => request.method) %>
-
-
- <% for key, values in params %>
- <% next if key == "BP-RETRY" %>
- <% for value in Array(values) %>
-
- <% end %>
- <% end %>
-
-
-
- <% rescue Exception => e %>
- <%=h "Couldn't render breakpoint link due to #{e.class} #{e.message}" %>
- <% end %>
-<% end %>
-
-<%
- clean_params = request.parameters.clone
- clean_params.delete("action")
- clean_params.delete("controller")
-
- request_dump = clean_params.empty? ? 'None' : clean_params.inspect.gsub(',', ",\n")
-%>
-
-Request
-<%=h request_dump %>
Headers:
<%=h response ? response.headers.inspect.gsub(',', ",\n") : 'None' %>diff --git a/actionpack/lib/action_controller/templates/rescues/_trace.rhtml b/actionpack/lib/action_controller/templates/rescues/_trace.rhtml index b322b0aaae..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/rescues/_trace.rhtml +++ b/actionpack/lib/action_controller/templates/rescues/_trace.rhtml @@ -1,26 +0,0 @@ -<% - traces = [ - ["Application Trace", @exception.application_backtrace], - ["Framework Trace", @exception.framework_backtrace], - ["Full Trace", @exception.clean_backtrace] - ] - names = traces.collect {|name, trace| name} -%> - -
RAILS_ROOT: <%= defined?(RAILS_ROOT) ? RAILS_ROOT : "unset" %>
<%= trace.join "\n" %>
- <%=h @exception.clean_message %>- -<%= render_file(@rescues_path + "/_trace.rhtml", false) %> - -<%= render_file(@rescues_path + "/_request_and_response.rhtml", false) %> diff --git a/actionpack/lib/action_controller/templates/rescues/layout.rhtml b/actionpack/lib/action_controller/templates/rescues/layout.rhtml index d38f3e67f9..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/rescues/layout.rhtml +++ b/actionpack/lib/action_controller/templates/rescues/layout.rhtml @@ -1,29 +0,0 @@ - - -
<%=h @exception.message %>
diff --git a/actionpack/lib/action_controller/templates/rescues/routing_error.rhtml b/actionpack/lib/action_controller/templates/rescues/routing_error.rhtml index ccfa858cce..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/rescues/routing_error.rhtml +++ b/actionpack/lib/action_controller/templates/rescues/routing_error.rhtml @@ -1,10 +0,0 @@ -<%=h @exception.message %>-<% unless @exception.failures.empty? %>
-
<%=h route.inspect.gsub('\\', '') %>
failed because <%=h reason.downcase %>- Showing <%=h @exception.file_name %> where line #<%=h @exception.line_number %> raised: -
<%=h @exception.message %>
-
-
-Extracted source (around line #<%=h @exception.line_number %>): -
<%=h @exception.source_extract %>
-
-<%=h @exception.sub_template_message %>
- -<% @real_exception = @exception - @exception = @exception.original_exception || @exception %> -<%= render_file(@rescues_path + "/_trace.rhtml", false) %> -<% @exception = @real_exception %> - -<%= render_file(@rescues_path + "/_request_and_response.rhtml", false) %> diff --git a/actionpack/lib/action_controller/templates/rescues/unknown_action.rhtml b/actionpack/lib/action_controller/templates/rescues/unknown_action.rhtml index 683379da10..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/rescues/unknown_action.rhtml +++ b/actionpack/lib/action_controller/templates/rescues/unknown_action.rhtml @@ -1,2 +0,0 @@ -<%=h @exception.message %>
diff --git a/actionpack/lib/action_controller/templates/scaffolds/edit.rhtml b/actionpack/lib/action_controller/templates/scaffolds/edit.rhtml index 63dff602a1..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/scaffolds/edit.rhtml +++ b/actionpack/lib/action_controller/templates/scaffolds/edit.rhtml @@ -1,7 +0,0 @@ -<%= flash[:notice] %>
- -<%= yield %> - - - diff --git a/actionpack/lib/action_controller/templates/scaffolds/list.rhtml b/actionpack/lib/action_controller/templates/scaffolds/list.rhtml index fea23dc66f..e69de29bb2 100644 --- a/actionpack/lib/action_controller/templates/scaffolds/list.rhtml +++ b/actionpack/lib/action_controller/templates/scaffolds/list.rhtml @@ -1,27 +0,0 @@ -<%= column.human_name %> | - <% end %> -|||
---|---|---|---|
<%= entry.send(column.name) %> | - <% end %> -<%= link_to "Show", :action => "show#{@scaffold_suffix}", :id => entry %> | -<%= link_to "Edit", :action => "edit#{@scaffold_suffix}", :id => entry %> | -<%= link_to "Destroy", {:action => "destroy#{@scaffold_suffix}", :id => entry}, { :confirm => "Are you sure?", :method => :post } %> | -
- <%= column.human_name %>: - <%= instance_variable_get("@#{@scaffold_singular_name}").send(column.name) %> -
-<% end %> - -<%= link_to "Edit", :action => "edit#{@scaffold_suffix}", :id => instance_variable_get("@#{@scaffold_singular_name}") %> | -<%= link_to "Back", :action => "list#{@scaffold_suffix}" %> diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb index 18d03f5a0b..1b3cf5d95e 100644 --- a/actionpack/lib/action_view/base.rb +++ b/actionpack/lib/action_view/base.rb @@ -4,8 +4,8 @@ module ActionView #:nodoc: class ActionViewError < StandardError #:nodoc: end - # Action View templates can be written in three ways. If the template file has a +.rhtml+ extension then it uses a mixture of ERb - # (included in Ruby) and HTML. If the template file has a +.rxml+ extension then Jim Weirich's Builder::XmlMarkup library is used. + # Action View templates can be written in three ways. If the template file has a +.erb+ (or +.rhtml+) extension then it uses a mixture of ERb + # (included in Ruby) and HTML. If the template file has a +.builder+ (or +.rxml+) extension then Jim Weirich's Builder::XmlMarkup library is used. # If the template file has a +.rjs+ extension then it will use ActionView::Helpers::PrototypeHelper::JavaScriptGenerator. # # = ERb @@ -77,7 +77,7 @@ module ActionView #:nodoc: # == Builder # # Builder templates are a more programmatic alternative to ERb. They are especially useful for generating XML content. An +XmlMarkup+ object - # named +xml+ is automatically made available to templates with a +.rxml+ extension. + # named +xml+ is automatically made available to templates with a +.builder+ extension. # # Here are some basic examples: # @@ -246,7 +246,6 @@ module ActionView #:nodoc: def render_file(template_path, use_full_path = true, local_assigns = {}) #:nodoc: @first_render ||= template_path template_path_without_extension, template_extension = path_and_extension(template_path) - if use_full_path if template_extension template_file_name = full_template_path(template_path_without_extension, template_extension) @@ -280,7 +279,7 @@ module ActionView #:nodoc: elsif options == :update update_page(&block) elsif options.is_a?(Hash) - options = options.reverse_merge(:type => :rhtml, :locals => {}, :use_full_path => true) + options = options.reverse_merge(:type => :erb, :locals => {}, :use_full_path => true) if options[:file] render_file(options[:file], options[:use_full_path], options[:locals]) @@ -294,7 +293,7 @@ module ActionView #:nodoc: end end - # Renders the +template+ which is given as a string as either rhtml or rxml depending on template_extension. + # Renders the +template+ which is given as a string as either erb or builder depending on template_extension. # The hash in local_assigns is made available as local variables. def render_template(template_extension, template, file_path = nil, local_assigns = {}) #:nodoc: if handler = @@template_handlers[template_extension] @@ -342,15 +341,21 @@ module ActionView #:nodoc: def delegate_template_exists?(template_path)#:nodoc: @@template_handlers.find { |k,| template_exists?(template_path, k) } end - + + def one_of(template_path, *extensions)#:nodoc: + extensions.detect{|ext| template_exists?(template_path, ext)} + end + def erb_template_exists?(template_path)#:nodoc: - template_exists?(template_path, :rhtml) + one_of(template_path, :erb, :rhtml) end - + alias :rhtml_template_exists? :erb_template_exists? + def builder_template_exists?(template_path)#:nodoc: - template_exists?(template_path, :rxml) + one_of(template_path, :builder, :rxml) end - + alias :rxml_template_exists? :builder_template_exists? + def javascript_template_exists?(template_path)#:nodoc: template_exists?(template_path, :rjs) end @@ -361,7 +366,7 @@ module ActionView #:nodoc: template_exists?(template_file_name, template_file_extension) else cached_template_extension(template_path) || - %w(erb builder javascript delegate).any? do |template_type| + %w(erb rhtml builder rxml javascript delegate).any? do |template_type| send("#{template_type}_template_exists?", template_path) end end @@ -401,11 +406,11 @@ module ActionView #:nodoc: def find_template_extension_for(template_path) if match = delegate_template_exists?(template_path) match.first.to_sym - elsif erb_template_exists?(template_path): :rhtml - elsif builder_template_exists?(template_path): :rxml + elsif extension = erb_template_exists?(template_path): extension + elsif extension = builder_template_exists?(template_path): extension elsif javascript_template_exists?(template_path): :rjs else - raise ActionViewError, "No rhtml, rxml, rjs or delegate template found for #{template_path} in #{@view_paths.inspect}" + raise ActionViewError, "No erb, builder, rhtml, rxml, rjs or delegate template found for #{template_path} in #{@view_paths.inspect}" end end @@ -464,7 +469,7 @@ module ActionView #:nodoc: def create_template_source(extension, template, render_symbol, locals) if template_requires_setup?(extension) body = case extension.to_sym - when :rxml + when :rxml, :builder "controller.response.content_type ||= 'application/xml'\n" + "xml = Builder::XmlMarkup.new(:indent => 2)\n" + template @@ -493,7 +498,7 @@ module ActionView #:nodoc: end def templates_requiring_setup - %w(rxml rjs) + %w(builder rxml rjs) end def assign_method_name(extension, template, file_name) @@ -523,7 +528,7 @@ module ActionView #:nodoc: line_offset = @@template_args[render_symbol].size if extension case extension.to_sym - when :rxml, :rjs + when :builder, :rxml, :rjs line_offset += 2 end end diff --git a/actionpack/lib/action_view/helpers/capture_helper.rb b/actionpack/lib/action_view/helpers/capture_helper.rb index 1d6ad56004..91cff4f981 100644 --- a/actionpack/lib/action_view/helpers/capture_helper.rb +++ b/actionpack/lib/action_view/helpers/capture_helper.rb @@ -14,7 +14,7 @@ module ActionView # content_for("name") is a wrapper for capture which will # make the fragment available by name to a yielding layout or template. # - # layout.rhtml: + # layout.erb: # # # @@ -28,7 +28,7 @@ module ActionView # # # - # view.rhtml + # view.erb # # This page shows an alert box! # @@ -42,13 +42,13 @@ module ActionView # instance variable. You can use this instance variable anywhere # in your templates and even in your layout. # - # Example of capture being used in a .rhtml page: + # Example of capture being used in a .erb page: # # <% @greeting = capture do %> # Welcome To my shiny new web page! # <% end %> # - # Example of capture being used in a .rxml page: + # Example of capture being used in a .builder page: # # @greeting = capture do # 'Welcome To my shiny new web page!' diff --git a/actionpack/lib/action_view/partials.rb b/actionpack/lib/action_view/partials.rb index 063ff5688d..c6049a4683 100644 --- a/actionpack/lib/action_view/partials.rb +++ b/actionpack/lib/action_view/partials.rb @@ -7,7 +7,7 @@ module ActionView # # <%= render :partial => "account" %> # - # This would render "advertiser/_account.rhtml" and pass the instance variable @account in as a local variable +account+ to + # This would render "advertiser/_account.erb" and pass the instance variable @account in as a local variable +account+ to # the template for display. # # In another template for Advertiser#buy, we could have: @@ -18,8 +18,8 @@ module ActionView # <%= render :partial => "ad", :locals => { :ad => ad } %> # <% end %> # - # This would first render "advertiser/_account.rhtml" with @buyer passed in as the local variable +account+, then render - # "advertiser/_ad.rhtml" and pass the local variable +ad+ to the template for display. + # This would first render "advertiser/_account.erb" with @buyer passed in as the local variable +account+, then render + # "advertiser/_ad.erb" and pass the local variable +ad+ to the template for display. # # == Rendering a collection of partials # @@ -30,7 +30,7 @@ module ActionView # # <%= render :partial => "ad", :collection => @advertisements %> # - # This will render "advertiser/_ad.rhtml" and pass the local variable +ad+ to the template for display. An iteration counter + # This will render "advertiser/_ad.erb" and pass the local variable +ad+ to the template for display. An iteration counter # will automatically be made available to the template with a name of the form +partial_name_counter+. In the case of the # example above, the template would be fed +ad_counter+. # @@ -43,7 +43,7 @@ module ActionView # # <%= render :partial => "advertisement/ad", :locals => { :ad => @advertisement } %> # - # This will render the partial "advertisement/_ad.rhtml" regardless of which controller this is being called from. + # This will render the partial "advertisement/_ad.erb" regardless of which controller this is being called from. module Partials # Deprecated, use render :partial def render_partial(partial_path, local_assigns = nil, deprecated_local_assigns = nil) #:nodoc: diff --git a/actionpack/test/controller/layout_test.rb b/actionpack/test/controller/layout_test.rb index cade6738a7..edf8f44b3a 100644 --- a/actionpack/test/controller/layout_test.rb +++ b/actionpack/test/controller/layout_test.rb @@ -110,7 +110,9 @@ class ExemptFromLayoutTest < Test::Unit::TestCase def test_rhtml_exempt_from_layout_status_should_prevent_layout_render ActionController::Base.exempt_from_layout :rhtml + assert @controller.send(:template_exempt_from_layout?, 'test.rhtml') + assert @controller.send(:template_exempt_from_layout?, 'hello.rhtml') get :hello assert_equal 'hello.rhtml', @response.body diff --git a/actionpack/test/controller/new_render_test.rb b/actionpack/test/controller/new_render_test.rb index d3967791a0..3eb84e6d24 100644 --- a/actionpack/test/controller/new_render_test.rb +++ b/actionpack/test/controller/new_render_test.rb @@ -60,12 +60,12 @@ class NewRenderTestController < ActionController::Base def render_file_with_instance_variables @secret = 'in the sauce' - path = File.join(File.dirname(__FILE__), '../fixtures/test/render_file_with_ivar.rhtml') + path = File.join(File.dirname(__FILE__), '../fixtures/test/render_file_with_ivar.erb') render :file => path end def render_file_with_locals - path = File.join(File.dirname(__FILE__), '../fixtures/test/render_file_with_locals.rhtml') + path = File.join(File.dirname(__FILE__), '../fixtures/test/render_file_with_locals.erb') render :file => path, :locals => {:secret => 'in the sauce'} end @@ -227,11 +227,11 @@ class NewRenderTestController < ActionController::Base end def hello_world_from_rxml_using_action - render :action => "hello_world.rxml" + render :action => "hello_world.builder" end def hello_world_from_rxml_using_template - render :template => "test/hello_world.rxml" + render :template => "test/hello_world.builder" end def head_with_location_header diff --git a/actionpack/test/controller/rescue_test.rb b/actionpack/test/controller/rescue_test.rb index f539546a1a..885ac0b8c0 100644 --- a/actionpack/test/controller/rescue_test.rb +++ b/actionpack/test/controller/rescue_test.rb @@ -111,7 +111,7 @@ class RescueTest < Test::Unit::TestCase def test_rescue_action_locally get :raises assert_response :internal_server_error - assert_template 'diagnostics.rhtml' + assert_template 'diagnostics.erb' assert @response.body.include?('RescueController#raises'), "Response should include controller and action." assert @response.body.include?("don't panic"), "Response should include exception message." end diff --git a/actionpack/test/fixtures/addresses/list.rhtml b/actionpack/test/fixtures/addresses/list.rhtml index c75e01eece..e69de29bb2 100644 --- a/actionpack/test/fixtures/addresses/list.rhtml +++ b/actionpack/test/fixtures/addresses/list.rhtml @@ -1 +0,0 @@ -We only need to get this far! diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_cookies_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_cookies_ivar.rhtml index 4e8a2d804c..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_cookies_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_cookies_ivar.rhtml @@ -1 +0,0 @@ -<%= @cookies[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_cookies_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_cookies_method.rhtml index 68e88bb746..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_cookies_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_cookies_method.rhtml @@ -1 +0,0 @@ -<%= cookies[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_flash_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_flash_ivar.rhtml index 4b4782b287..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_flash_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_flash_ivar.rhtml @@ -1 +0,0 @@ -<%= @flash[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_flash_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_flash_method.rhtml index f7f9d0913a..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_flash_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_flash_method.rhtml @@ -1 +0,0 @@ -<%= flash[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_headers_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_headers_ivar.rhtml index 1176c93ad8..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_headers_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_headers_ivar.rhtml @@ -1 +0,0 @@ -<%= @headers[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_headers_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_headers_method.rhtml index 308c4eb6ba..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_headers_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_headers_method.rhtml @@ -1 +0,0 @@ -<%= headers[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_params_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_params_ivar.rhtml index 1eea68757f..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_params_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_params_ivar.rhtml @@ -1 +0,0 @@ -<%= @params[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_params_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_params_method.rhtml index 7e349b4ca0..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_params_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_params_method.rhtml @@ -1 +0,0 @@ -<%= params[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_request_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_request_ivar.rhtml index a1680c23d5..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_request_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_request_ivar.rhtml @@ -1 +0,0 @@ -<%= @request.method %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_request_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_request_method.rhtml index 0c74cf1c1b..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_request_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_request_method.rhtml @@ -1 +0,0 @@ -<%= request.method %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_response_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_response_ivar.rhtml index 2f12d2ce32..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_response_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_response_ivar.rhtml @@ -1 +0,0 @@ -<%= @response.body %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_response_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_response_method.rhtml index 948c75929a..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_response_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_response_method.rhtml @@ -1 +0,0 @@ -<%= response.body %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_session_ivar.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_session_ivar.rhtml index 3acc1b8529..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_session_ivar.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_session_ivar.rhtml @@ -1 +0,0 @@ -<%= @session[:test] %> diff --git a/actionpack/test/fixtures/deprecated_instance_variables/_session_method.rhtml b/actionpack/test/fixtures/deprecated_instance_variables/_session_method.rhtml index a899387c47..e69de29bb2 100644 --- a/actionpack/test/fixtures/deprecated_instance_variables/_session_method.rhtml +++ b/actionpack/test/fixtures/deprecated_instance_variables/_session_method.rhtml @@ -1 +0,0 @@ -<%= session[:test] %> diff --git a/actionpack/test/fixtures/fun/games/hello_world.rhtml b/actionpack/test/fixtures/fun/games/hello_world.rhtml index 1ebfbe2539..e69de29bb2 100644 --- a/actionpack/test/fixtures/fun/games/hello_world.rhtml +++ b/actionpack/test/fixtures/fun/games/hello_world.rhtml @@ -1 +0,0 @@ -Living in a nested world \ No newline at end of file diff --git a/actionpack/test/fixtures/layouts/builder.rxml b/actionpack/test/fixtures/layouts/builder.rxml index 729af4b8bc..e69de29bb2 100644 --- a/actionpack/test/fixtures/layouts/builder.rxml +++ b/actionpack/test/fixtures/layouts/builder.rxml @@ -1,3 +0,0 @@ -xml.wrapper do - xml << @content_for_layout -end \ No newline at end of file diff --git a/actionpack/test/fixtures/layouts/standard.rhtml b/actionpack/test/fixtures/layouts/standard.rhtml index 368764e6f4..e69de29bb2 100644 --- a/actionpack/test/fixtures/layouts/standard.rhtml +++ b/actionpack/test/fixtures/layouts/standard.rhtml @@ -1 +0,0 @@ -<%= @content_for_layout %><%= @variable_for_layout %> \ No newline at end of file diff --git a/actionpack/test/fixtures/layouts/talk_from_action.rhtml b/actionpack/test/fixtures/layouts/talk_from_action.rhtml index 187aab07a2..e69de29bb2 100644 --- a/actionpack/test/fixtures/layouts/talk_from_action.rhtml +++ b/actionpack/test/fixtures/layouts/talk_from_action.rhtml @@ -1,2 +0,0 @@ -Beautiful modules!
\ No newline at end of file diff --git a/actionpack/test/fixtures/test/_customer.rhtml b/actionpack/test/fixtures/test/_customer.rhtml index 872d8c44e6..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_customer.rhtml +++ b/actionpack/test/fixtures/test/_customer.rhtml @@ -1 +0,0 @@ -Hello: <%= customer.name %> \ No newline at end of file diff --git a/actionpack/test/fixtures/test/_customer_greeting.rhtml b/actionpack/test/fixtures/test/_customer_greeting.rhtml index 6acbcb20c4..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_customer_greeting.rhtml +++ b/actionpack/test/fixtures/test/_customer_greeting.rhtml @@ -1 +0,0 @@ -<%= greeting %>: <%= customer_greeting.name %> \ No newline at end of file diff --git a/actionpack/test/fixtures/test/_hash_object.rhtml b/actionpack/test/fixtures/test/_hash_object.rhtml index 037a7368d6..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_hash_object.rhtml +++ b/actionpack/test/fixtures/test/_hash_object.rhtml @@ -1 +0,0 @@ -<%= hash_object[:first_name] %> \ No newline at end of file diff --git a/actionpack/test/fixtures/test/_hello.rxml b/actionpack/test/fixtures/test/_hello.rxml index ef52f632d1..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_hello.rxml +++ b/actionpack/test/fixtures/test/_hello.rxml @@ -1 +0,0 @@ -xm.hello \ No newline at end of file diff --git a/actionpack/test/fixtures/test/_partial_only.rhtml b/actionpack/test/fixtures/test/_partial_only.rhtml index a44b3eed40..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_partial_only.rhtml +++ b/actionpack/test/fixtures/test/_partial_only.rhtml @@ -1 +0,0 @@ -only partial \ No newline at end of file diff --git a/actionpack/test/fixtures/test/_person.rhtml b/actionpack/test/fixtures/test/_person.rhtml index b2e5688956..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/_person.rhtml +++ b/actionpack/test/fixtures/test/_person.rhtml @@ -1,2 +0,0 @@ -Second: <%= name %> -Third: <%= @name %> diff --git a/actionpack/test/fixtures/test/action_talk_to_layout.rhtml b/actionpack/test/fixtures/test/action_talk_to_layout.rhtml index 36e896daa8..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/action_talk_to_layout.rhtml +++ b/actionpack/test/fixtures/test/action_talk_to_layout.rhtml @@ -1,2 +0,0 @@ -<% @title = "Talking to the layout" -%> -Action was here! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/block_content_for.rhtml b/actionpack/test/fixtures/test/block_content_for.rhtml index 9510337365..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/block_content_for.rhtml +++ b/actionpack/test/fixtures/test/block_content_for.rhtml @@ -1,2 +0,0 @@ -<% block_content_for :title do 'Putting stuff in the title!' end %> -Great stuff! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/capturing.rhtml b/actionpack/test/fixtures/test/capturing.rhtml index 1addaa40d9..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/capturing.rhtml +++ b/actionpack/test/fixtures/test/capturing.rhtml @@ -1,4 +0,0 @@ -<% days = capture do %> - Dreamy days -<% end %> -<%= days %> \ No newline at end of file diff --git a/actionpack/test/fixtures/test/content_for.rhtml b/actionpack/test/fixtures/test/content_for.rhtml index 0e47ca8c3d..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/content_for.rhtml +++ b/actionpack/test/fixtures/test/content_for.rhtml @@ -1,2 +0,0 @@ -<% content_for :title do %>Putting stuff in the title!<% end %> -Great stuff! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/dot.directory/render_file_with_ivar.rhtml b/actionpack/test/fixtures/test/dot.directory/render_file_with_ivar.rhtml index 8b8a449236..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/dot.directory/render_file_with_ivar.rhtml +++ b/actionpack/test/fixtures/test/dot.directory/render_file_with_ivar.rhtml @@ -1 +0,0 @@ -The secret is <%= @secret %> diff --git a/actionpack/test/fixtures/test/erb_content_for.rhtml b/actionpack/test/fixtures/test/erb_content_for.rhtml index c3bdd13643..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/erb_content_for.rhtml +++ b/actionpack/test/fixtures/test/erb_content_for.rhtml @@ -1,2 +0,0 @@ -<% erb_content_for :title do %>Putting stuff in the title!<% end %> -Great stuff! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/greeting.rhtml b/actionpack/test/fixtures/test/greeting.rhtml index 62fb0293f0..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/greeting.rhtml +++ b/actionpack/test/fixtures/test/greeting.rhtml @@ -1 +0,0 @@ -This is grand!
diff --git a/actionpack/test/fixtures/test/hello.rxml b/actionpack/test/fixtures/test/hello.rxml index 82a4a310d3..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello.rxml +++ b/actionpack/test/fixtures/test/hello.rxml @@ -1,4 +0,0 @@ -xml.html do - xml.p "Hello #{@name}" - xml << render_file("test/greeting") -end \ No newline at end of file diff --git a/actionpack/test/fixtures/test/hello_world.rhtml b/actionpack/test/fixtures/test/hello_world.rhtml index 6769dd60bd..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello_world.rhtml +++ b/actionpack/test/fixtures/test/hello_world.rhtml @@ -1 +0,0 @@ -Hello world! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/hello_world.rxml b/actionpack/test/fixtures/test/hello_world.rxml index bffd2191ba..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello_world.rxml +++ b/actionpack/test/fixtures/test/hello_world.rxml @@ -1,3 +0,0 @@ -xml.html do - xml.p "Hello" -end \ No newline at end of file diff --git a/actionpack/test/fixtures/test/hello_world_container.rxml b/actionpack/test/fixtures/test/hello_world_container.rxml index e48d75c405..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello_world_container.rxml +++ b/actionpack/test/fixtures/test/hello_world_container.rxml @@ -1,3 +0,0 @@ -xml.test do - render :partial => 'hello', :locals => { :xm => xml } -end \ No newline at end of file diff --git a/actionpack/test/fixtures/test/hello_world_with_layout_false.rhtml b/actionpack/test/fixtures/test/hello_world_with_layout_false.rhtml index 6769dd60bd..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello_world_with_layout_false.rhtml +++ b/actionpack/test/fixtures/test/hello_world_with_layout_false.rhtml @@ -1 +0,0 @@ -Hello world! \ No newline at end of file diff --git a/actionpack/test/fixtures/test/hello_xml_world.rxml b/actionpack/test/fixtures/test/hello_xml_world.rxml index 02b14fe87c..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/hello_xml_world.rxml +++ b/actionpack/test/fixtures/test/hello_xml_world.rxml @@ -1,11 +0,0 @@ -xml.html do - xml.head do - xml.title "Hello World" - end - - xml.body do - xml.p "abes" - xml.p "monks" - xml.p "wiseguys" - end -end \ No newline at end of file diff --git a/actionpack/test/fixtures/test/list.rhtml b/actionpack/test/fixtures/test/list.rhtml index cd0ab45d26..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/list.rhtml +++ b/actionpack/test/fixtures/test/list.rhtml @@ -1 +0,0 @@ -<%= @test_unchanged = 'goodbye' %><%= render_collection_of_partials "customer", @customers %><%= @test_unchanged %> diff --git a/actionpack/test/fixtures/test/non_erb_block_content_for.rxml b/actionpack/test/fixtures/test/non_erb_block_content_for.rxml index 6ff6db0f95..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/non_erb_block_content_for.rxml +++ b/actionpack/test/fixtures/test/non_erb_block_content_for.rxml @@ -1,4 +0,0 @@ -content_for :title do - 'Putting stuff in the title!' -end -xml << "\nGreat stuff!" \ No newline at end of file diff --git a/actionpack/test/fixtures/test/potential_conflicts.rhtml b/actionpack/test/fixtures/test/potential_conflicts.rhtml index a5e964e359..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/potential_conflicts.rhtml +++ b/actionpack/test/fixtures/test/potential_conflicts.rhtml @@ -1,4 +0,0 @@ -First: <%= @name %> -<%= render :partial => "person", :locals => { :name => "Stephan" } -%> -Fourth: <%= @name %> -Fifth: <%= name %> \ No newline at end of file diff --git a/actionpack/test/fixtures/test/render_file_with_ivar.rhtml b/actionpack/test/fixtures/test/render_file_with_ivar.rhtml index 8b8a449236..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/render_file_with_ivar.rhtml +++ b/actionpack/test/fixtures/test/render_file_with_ivar.rhtml @@ -1 +0,0 @@ -The secret is <%= @secret %> diff --git a/actionpack/test/fixtures/test/render_file_with_locals.rhtml b/actionpack/test/fixtures/test/render_file_with_locals.rhtml index ebe09faee6..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/render_file_with_locals.rhtml +++ b/actionpack/test/fixtures/test/render_file_with_locals.rhtml @@ -1 +0,0 @@ -The secret is <%= secret %> diff --git a/actionpack/test/fixtures/test/render_to_string_test.rhtml b/actionpack/test/fixtures/test/render_to_string_test.rhtml index 6e267e8634..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/render_to_string_test.rhtml +++ b/actionpack/test/fixtures/test/render_to_string_test.rhtml @@ -1 +0,0 @@ -The value of foo is: ::<%= @foo %>:: diff --git a/actionpack/test/fixtures/test/update_element_with_capture.rhtml b/actionpack/test/fixtures/test/update_element_with_capture.rhtml index fa3ef200f9..e69de29bb2 100644 --- a/actionpack/test/fixtures/test/update_element_with_capture.rhtml +++ b/actionpack/test/fixtures/test/update_element_with_capture.rhtml @@ -1,9 +0,0 @@ -<% replacement_function = update_element_function("products", :action => :update) do %> -Product 1
-Product 2
-<% end %> -<%= javascript_tag(replacement_function) %> - -<% update_element_function("status", :action => :update, :binding => binding) do %> - You bought something! -<% end %> -- cgit v1.2.3