Class: AssertSelectController

Inherits:
ActionController::Base
  • Object
show all
Defined in:
lib/vendor/plugins/rspec-rails/spec/spec/rails/matchers/assert_select_spec.rb

Overview

assert_select plugins for Rails

Copyright © 2006 Assaf Arkin, under Creative Commons Attribution and/or MIT License Developed for co.mments.com Code and documention: labnotes.org

Instance Method Summary collapse

Instance Method Details

#htmlObject



15
16
17
18
# File 'lib/vendor/plugins/rspec-rails/spec/spec/rails/matchers/assert_select_spec.rb', line 15

def html()
  render :text=>@content, :layout=>false, :content_type=>Mime::HTML
  @content = nil
end

#response=(content) ⇒ Object



11
12
13
# File 'lib/vendor/plugins/rspec-rails/spec/spec/rails/matchers/assert_select_spec.rb', line 11

def response=(content)
  @content = content
end

#rjsObject



20
21
22
23
24
25
26
# File 'lib/vendor/plugins/rspec-rails/spec/spec/rails/matchers/assert_select_spec.rb', line 20

def rjs()
  update = @update
  render :update do |page|
    update.call page
  end
  @update = nil
end

#xmlObject



28
29
30
31
# File 'lib/vendor/plugins/rspec-rails/spec/spec/rails/matchers/assert_select_spec.rb', line 28

def xml()
  render :text=>@content, :layout=>false, :content_type=>Mime::XML
  @content = nil
end