From f4b5e18424ec4e7fe76075e9c2f300bc97ce705d Mon Sep 17 00:00:00 2001 From: Alberto Rocha Date: Mon, 7 Oct 2024 14:28:15 -0300 Subject: [PATCH] Fix #vc_test_request example (#2119) * Fix #vc_test_request example Fix the example provided for #vc_test_request to use "vc_test_request" instead of "request". * Update CHANGELOG --- docs/CHANGELOG.md | 4 ++++ docs/api.md | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 12cc60a0a..f48c475aa 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -22,6 +22,10 @@ nav_order: 5 *Denis Pasin* +* Fix the example of #vc_test_request in the API reference to use the correct method name. + + *Alberto Rocha* + ## 3.16.0 * Add template information to multiple template error messages. diff --git a/docs/api.md b/docs/api.md index e2d5f3b18..19006ffed 100644 --- a/docs/api.md +++ b/docs/api.md @@ -343,7 +343,7 @@ Access the request used by `render_inline`: ```ruby test "component does not render in Firefox" do - request.env["HTTP_USER_AGENT"] = "Mozilla/5.0" + vc_test_request.env["HTTP_USER_AGENT"] = "Mozilla/5.0" render_inline(NoFirefoxComponent.new) refute_component_rendered end