mirror of
https://github.com/discourse/discourse.git
synced 2025-06-03 15:45:25 +08:00
DEV: Update custom array implementations for Ember 5 compatibility (#24435)
In the long term we should aim to modernize these places, but for now this change will make them compatible with Ember 5.x (while maintaining compatibility with Ember 3.28)
This commit is contained in:
@ -48,4 +48,25 @@ describe "Topic page", type: :system do
|
||||
expect(".codeblock-button-wrapper").to be_present
|
||||
end
|
||||
end
|
||||
|
||||
context "with a gap" do
|
||||
before do
|
||||
post2 = Fabricate(:post, topic: topic, cooked: "post2")
|
||||
post3 = Fabricate(:post, topic: topic, cooked: "post3")
|
||||
post4 = Fabricate(:post, topic: topic, cooked: "post4")
|
||||
|
||||
PostDestroyer.new(Discourse.system_user, post2).destroy
|
||||
PostDestroyer.new(Discourse.system_user, post3).destroy
|
||||
|
||||
sign_in Fabricate(:admin)
|
||||
end
|
||||
|
||||
it "displays the gap to admins, and alows them to expand it" do
|
||||
visit "/t/#{topic.slug}/#{topic.id}"
|
||||
|
||||
expect(page).to have_css(".topic-post", count: 2)
|
||||
find(".post-stream .gap").click()
|
||||
expect(page).to have_css(".topic-post", count: 4)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user