instance method save_and_open_page

Ruby on Rails 8.1.2

Since v7.2.3

Available in: v7.2.3 v8.0.4 v8.1.2

Signature

save_and_open_page(path = html_dump_default_path)

Saves the content of response body to a file and tries to open it in your browser. Launchy must be present in your Gemfile for the page to open automatically.

Parameters

path opt = html_dump_default_path
Source
# File actionpack/lib/action_dispatch/testing/test_helpers/page_dump_helper.rb, line 10
      def save_and_open_page(path = html_dump_default_path)
        save_page(path).tap { |s_path| open_file(s_path) }
      end

Defined in actionpack/lib/action_dispatch/testing/test_helpers/page_dump_helper.rb line 10 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionDispatch::TestHelpers::PageDumpHelper

Type at least 2 characters to search.

↑↓ navigate · open · esc close