Introduce backend for reports

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2019-07-23 13:49:22 +02:00
parent 33a8da4570
commit aef841e192
36 changed files with 2028 additions and 36 deletions

View File

@@ -202,4 +202,24 @@ defmodule Mobilizon.Factory do
actor: build(:actor)
}
end
def report_factory do
%Mobilizon.Reports.Report{
content: "This is problematic",
status: :open,
uri: "http://mobilizon.test/report/deae1020-54b8-47df-9eea-d8c0e943e57f/activity",
reported: build(:actor),
reporter: build(:actor),
event: build(:event),
comments: build_list(1, :comment)
}
end
def report_note_factory do
%Mobilizon.Reports.Note{
content: "My opinion",
moderator: build(:actor),
report: build(:report)
}
end
end