mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Make assertions in integration sessions proxy to the test instance (only for sessions created via open_session)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3836 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
parent
51d6bc2807
commit
8152695b80
1 changed files with 3 additions and 0 deletions
|
@ -488,6 +488,9 @@ module ActionController
|
|||
klass.send(:define_method, name) { |*args| tests.send(name, *args) }
|
||||
end
|
||||
|
||||
# delegate add_assertion to the test case
|
||||
klass.send(:define_method, :add_assertion) { tests.add_assertion }
|
||||
|
||||
yield session if block_given?
|
||||
session
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue