Skip to content

Commit

Permalink
Update spec/helpers/notifications_helper_spec.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
julianguyen committed Jul 8, 2024
1 parent 00ae24d commit 1ad5079
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions spec/helpers/notifications_helper_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
uid: 'uid',
user_id: 1
}
expect(new_ally_request_link(uniqueid, data)).to eq('<div id="uniqueid"><div>&lt;a href=&quot;/profile?uid=uid&quot;&gt;Julia Nguyen&lt;/a&gt; sent an ally request!</div><div><a rel="nofollow" data-method="post" href="/allies/add?ally_id=1">Accept</a> | <a data-confirm="Are you sure?" rel="nofollow" data-method="post" href="/allies/remove?ally_id=1">Reject</a></div></div>')
expect(new_ally_request_link(uniqueid, data)).to eq('<div id="uniqueid"><div><a href="/profile?uid=uid">Julia Nguyen</a> sent an ally request!</div><div><a rel="nofollow" data-method="post" href="/allies/add?ally_id=1">Accept</a> | <a data-confirm="Are you sure?" rel="nofollow" data-method="post" href="/allies/remove?ally_id=1">Reject</a></div></div>')
end

it 'sanitizes and returns the correct link' do
Expand All @@ -68,7 +68,7 @@
uid: 'uid',
user_id: 1
}
expect(new_ally_request_link(uniqueid, data)).to eq('<div id="uniqueid"><div>&lt;a href=&quot;/profile?uid=uid&quot;&gt;[email protected]&lt;/a&gt; sent an ally request!</div><div><a rel="nofollow" data-method="post" href="/allies/add?ally_id=1">Accept</a> | <a data-confirm="Are you sure?" rel="nofollow" data-method="post" href="/allies/remove?ally_id=1">Reject</a></div></div>')
expect(new_ally_request_link(uniqueid, data)).to eq('<div id="uniqueid"><div><a href="/profile?uid=uid">[email protected]</a> sent an ally request!</div><div><a rel="nofollow" data-method="post" href="/allies/add?ally_id=1">Accept</a> | <a data-confirm="Are you sure?" rel="nofollow" data-method="post" href="/allies/remove?ally_id=1">Reject</a></div></div>')
end
end

Expand Down

0 comments on commit 1ad5079

Please sign in to comment.