-
-
Notifications
You must be signed in to change notification settings - Fork 392
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add possibility of reporting blog posts
* fix report blogs * lint * lint
- Loading branch information
1 parent
51b81b3
commit 79d0530
Showing
3 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -59,3 +59,4 @@ | |
</div> | ||
<%= attachments_for post %> | ||
<%= comments_for post %> | ||
<%= cell("decidim/flag_modal", post) %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# frozen_string_literal: true | ||
|
||
require "spec_helper" | ||
|
||
describe "Report a post", type: :system do | ||
include_context "with a component" | ||
|
||
let(:manifest_name) { "blogs" } | ||
let!(:posts) { create_list(:post, 3, component:) } | ||
let(:reportable) { posts.first } | ||
let(:reportable_path) { resource_locator(reportable).path } | ||
let!(:user) { create(:user, :confirmed, organization:) } | ||
|
||
let!(:component) do | ||
create(:post_component, | ||
manifest:, | ||
participatory_space: participatory_process) | ||
end | ||
|
||
include_examples "reports" | ||
end |