tests: add missing controller tests.
This commit is contained in:
@@ -4,10 +4,7 @@ module Explore
|
||||
class PostsControllerTest < ActionDispatch::IntegrationTest
|
||||
context "in all cases" do
|
||||
setup do
|
||||
@user = create(:user)
|
||||
as_user do
|
||||
create(:post)
|
||||
end
|
||||
@post = create(:post)
|
||||
end
|
||||
|
||||
context "#popular" do
|
||||
@@ -17,6 +14,15 @@ module Explore
|
||||
end
|
||||
end
|
||||
|
||||
context "#curated" do
|
||||
should "render" do
|
||||
@builder = create(:builder_user)
|
||||
@post.add_favorite!(@builder)
|
||||
get curated_explore_posts_path
|
||||
assert_response :success
|
||||
end
|
||||
end
|
||||
|
||||
context "#searches" do
|
||||
should "render" do
|
||||
get searches_explore_posts_path
|
||||
|
||||
Reference in New Issue
Block a user