This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class User < ActiveRecord::Base | |
# Omitted | |
def send_devise_notification(notification, *args) | |
devise_mailer.send(notification, self, *args).deliver_later | |
end | |
end | |
test 'send_devise_notification queues into activejob' do | |
@user.save | |
assert_equal enqueued_jobs.size, 1 # Passes | |
assert_equal Sidekiq::Extensions::DelayedMailer.jobs.size, 1 #Fails | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment