Use UrlHelper no console do Rails

$ rails c
> helper.link_to 'foo', 'hoge'
=> "<a href="hoge"">foo</a>""
> app.url_for(controller: 'articles'