FEATURE: Send notifications to admins when new features are released (#19460)

This commit adds a new notification that gets sent to admins when the site gets new features after an upgrade/deploy. Clicking on the notification takes the admin to the admin dashboard at `/admin` where they can see the new features under the "New Features" section.

Internal topic: t/87166.
This commit is contained in:
Osama Sayegh
2022-12-15 20:12:53 +03:00
committed by GitHub
parent d9806b5314
commit 1c03d6f9b9
15 changed files with 289 additions and 8 deletions

View File

@ -213,4 +213,14 @@ RSpec.describe DiscourseUpdates do
expect(result[2]["title"]).to eq("Bells")
end
end
describe "#get_last_viewed_feature_date" do
fab!(:user) { Fabricate(:user) }
it "returns an ActiveSupport::TimeWithZone object" do
time = Time.zone.parse("2022-12-13T21:33:59Z")
DiscourseUpdates.bump_last_viewed_feature_date(user.id, time)
expect(DiscourseUpdates.get_last_viewed_feature_date(user.id)).to eq(time)
end
end
end