instance method
save_page
Ruby on Rails 7.2.3
Since v7.2.3 PrivateSignature
save_page(path = html_dump_default_path)
No documentation comment.
Parameters
-
pathopt = html_dump_default_path
Source
# File actionpack/lib/action_dispatch/testing/test_helpers/page_dump_helper.rb, line 15
def save_page(path = html_dump_default_path)
raise InvalidResponse.new("Response is a redirection!") if response.redirection?
path = Pathname.new(path)
path.dirname.mkpath
File.write(path, response.body)
path
end
Defined in actionpack/lib/action_dispatch/testing/test_helpers/page_dump_helper.rb line 15
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionDispatch::TestHelpers::PageDumpHelper