DEV: Apply syntax_tree formatting to plugins/*

This commit is contained in:
David Taylor
2023-01-06 20:42:16 +00:00
parent 93e2dad656
commit 055310cea4
110 changed files with 3712 additions and 3158 deletions

View File

@ -4,18 +4,11 @@ describe "Local dates", type: :system, js: true do
fab!(:topic) { Fabricate(:topic) }
fab!(:user) { Fabricate(:user) }
before do
create_post(
user: user,
topic: topic,
title: "Date range test post",
raw: <<~RAW
before { create_post(user: user, topic: topic, title: "Date range test post", raw: <<~RAW) }
First option: [date=2022-12-15 time=14:19:00 timezone="Asia/Singapore"]
Second option: [date=2022-12-15 time=01:20:00 timezone="Asia/Singapore"], or [date=2022-12-15 time=02:40:00 timezone="Asia/Singapore"]
Third option: [date-range from=2022-12-15T11:25:00 to=2022-12-16T00:26:00 timezone="Asia/Singapore"] or [date-range from=2022-12-22T11:57:00 to=2022-12-23T11:58:00 timezone="Asia/Singapore"]
RAW
)
end
let(:topic_page) { PageObjects::Pages::Topic.new }
@ -53,12 +46,18 @@ describe "Local dates", type: :system, js: true do
post_dates[3].click
tippy_date = topic_page.find(".tippy-content .current .date-time")
expect(tippy_date).to have_text("Thursday, December 15, 2022\n11:25 AM → 12:26 AM", exact: true)
expect(tippy_date).to have_text(
"Thursday, December 15, 2022\n11:25 AM → 12:26 AM",
exact: true,
)
post_dates[5].click
tippy_date = topic_page.find(".tippy-content .current .date-time")
expect(tippy_date).to have_text("Thursday, December 22, 2022 11:57 AM → Friday, December 23, 2022 11:58 AM", exact: true)
expect(tippy_date).to have_text(
"Thursday, December 22, 2022 11:57 AM → Friday, December 23, 2022 11:58 AM",
exact: true,
)
end
end
end