DEV: Use explicit ordering so spec is realiable

This commit is contained in:
Rafael dos Santos Silva 2020-08-07 15:15:39 -03:00
parent f179510a68
commit 32f6c5c07e
No known key found for this signature in database
GPG Key ID: 5E50360227B34938
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ describe UserSummarySerializer do
topic = Fabricate(:topic)
post = Fabricate(:post_with_external_links, user: topic.user, topic: topic)
TopicLink.extract_from(post)
topic.topic_links.each_with_index do |link, index|
TopicLink.where(topic_id: topic.id).order(url: :asc).each_with_index do |link, index|
index.times do |i|
TopicLinkClick.create(topic_link: link, ip_address: "192.168.1.#{i + 1}")
end