Test that own edits are streamed
This commit is contained in:
parent
75dad5229b
commit
a762184cfd
1 changed files with 11 additions and 0 deletions
|
@ -397,6 +397,17 @@ test "it streams edits in the 'user' stream", %{user: user, token: oauth_token}
|
||||||
assert_receive {:render_with_user, _, "status_update.json", ^edited}
|
assert_receive {:render_with_user, _, "status_update.json", ^edited}
|
||||||
refute Streamer.filtered_by_user?(user, edited)
|
refute Streamer.filtered_by_user?(user, edited)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
test "it streams own edits in the 'user' stream", %{user: user, token: oauth_token} do
|
||||||
|
{:ok, activity} = CommonAPI.post(user, %{status: "hey"})
|
||||||
|
|
||||||
|
Streamer.get_topic_and_add_socket("user", user, oauth_token)
|
||||||
|
{:ok, edited} = CommonAPI.update(user, activity, %{status: "mew mew"})
|
||||||
|
edited = Pleroma.Activity.normalize(edited)
|
||||||
|
|
||||||
|
assert_receive {:render_with_user, _, "status_update.json", ^edited}
|
||||||
|
refute Streamer.filtered_by_user?(user, edited)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
describe "public streams" do
|
describe "public streams" do
|
||||||
|
|
Loading…
Reference in a new issue