diff --git a/guides/source/testing.md b/guides/source/testing.md index b784098fbb..8ad1eed72c 100644 --- a/guides/source/testing.md +++ b/guides/source/testing.md @@ -905,8 +905,10 @@ Testing Routes Like everything else in your Rails application, it is recommended that you test your routes. An example test for a route in the default `show` action of `Articles` controller above should look like: ```ruby -test "should route to article" do - assert_routing '/articles/1', {controller: "articles", action: "show", id: "1"} +class ArticleRoutesTest < ActionController::TestCase + test "should route to article" do + assert_routing '/articles/1', { controller: "articles", action: "show", id: "1" } + end end ```