tests: eliminate as_user helper.
This commit is contained in:
@@ -4,9 +4,7 @@ class RecommendedPostsControllerTest < ActionDispatch::IntegrationTest
|
||||
context "The recommended posts controller" do
|
||||
setup do
|
||||
@user = travel_to(1.month.ago) {create(:user)}
|
||||
as_user do
|
||||
@post = create(:post, :tag_string => "aaaa")
|
||||
end
|
||||
@post = as(@user) { create(:post, tag_string: "aaaa") }
|
||||
RecommenderService.stubs(:enabled?).returns(true)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user