discourse/spec/services/push_notification_pusher_sp...

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
458 B
Ruby
Raw Normal View History

# frozen_string_literal: true
require 'rails_helper'
RSpec.describe PushNotificationPusher do
it "returns badges url by default" do
expect(PushNotificationPusher.get_badge).to eq("/assets/push-notifications/discourse.png")
end
it "returns custom badges url" do
upload = Fabricate(:upload)
SiteSetting.push_notifications_icon = upload
expect(PushNotificationPusher.get_badge)
.to eq(UrlHelper.absolute(upload.url))
end
end