class PrototypeHelperBaseTest

Attributes

formats[RW]
output_buffer[RW]

Public Instance Methods

setup() click to toggle source
# File test/template/prototype_helper_test.rb, line 47
def setup
  super
  @template = self
end
update_details(details) { || ... } click to toggle source
# File test/template/prototype_helper_test.rb, line 42
def update_details(details)
  @details = details
  yield if block_given?
end
url_for(options) click to toggle source
# File test/template/prototype_helper_test.rb, line 52
def url_for(options)
  if options.is_a?(String)
    options
  else
    url =  "http://www.example.com/"
    url << options[:action].to_s if options and options[:action]
    url << "?a=#{options[:a]}" if options && options[:a]
    url << "&b=#{options[:b]}" if options && options[:a] && options[:b]
    url
  end
end

Protected Instance Methods

create_generator() { |*args| ... } click to toggle source
# File test/template/prototype_helper_test.rb, line 73
def create_generator
  block = Proc.new { |*args| yield(*args) if block_given? }
  JavaScriptGenerator.new self, &block
end
protect_against_forgery?() click to toggle source
# File test/template/prototype_helper_test.rb, line 69
def protect_against_forgery?
  false
end
request_forgery_protection_token() click to toggle source
# File test/template/prototype_helper_test.rb, line 65
def request_forgery_protection_token
  nil
end