mirror of
https://github.com/discourse/discourse.git
synced 2024-11-30 10:05:24 +08:00
0f4beab0fb
This enables cops related to RSpec `subject`. See https://github.com/discourse/rubocop-discourse/pull/32
14 lines
330 B
Ruby
14 lines
330 B
Ruby
# frozen_string_literal: true
|
|
|
|
RSpec.describe SubscriptionMailer do
|
|
subject(:mail) { SubscriptionMailer.confirm_unsubscribe(user) }
|
|
|
|
fab!(:user) { Fabricate(:user) }
|
|
|
|
it "contains the right URL" do
|
|
expect(mail.body).to include(
|
|
"#{Discourse.base_url}/email/unsubscribe/#{UnsubscribeKey.last.key}",
|
|
)
|
|
end
|
|
end
|