mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
DEV: Fix randomly failing search spec.
This commit is contained in:
parent
b360d4289e
commit
c10861da2f
@ -347,13 +347,15 @@ describe Search do
|
||||
)
|
||||
|
||||
post2 = Fabricate(:post,
|
||||
raw: "I think winter winter winter winter winter will end soon",
|
||||
raw: "I think #{'winter' * 20} will end soon",
|
||||
topic: Fabricate(:topic, title: "dragon john snow summer", category: category)
|
||||
)
|
||||
|
||||
result = Search.execute('winter')
|
||||
|
||||
expect(result.posts).to eq([post, post2, category.topic.first_post])
|
||||
expect(result.posts.pluck(:id)).to eq([
|
||||
post.id, category.topic.first_post.id, post2.id
|
||||
])
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user